Interface Image (2.0.0)

public interface Image extends Serializable

Image represents an image that can be manipulated by the ImagesService.

Implements

Serializable

Methods

getBlobKey()

public abstract @Nullable BlobKey getBlobKey()

If this image is backed by a blob, return the associated BlobKey. If this method returns non-null, none of the other methods will currently be available.

Returns
TypeDescription
@org.checkerframework.checker.nullness.qual.Nullable com.google.appengine.api.blobstore.BlobKey

getFormat()

public abstract @Nullable Image.Format getFormat()

Gets the encoding format of the image.

Returns
TypeDescription
@org.checkerframework.checker.nullness.qual.Nullable com.google.appengine.api.images.Image.Format

image format

getHeight()

public abstract int getHeight()

Gets the height of the image.

Returns
TypeDescription
int

image height

getImageData()

public abstract byte @Nullable [] getImageData()

Gets the raw imageData of the image.

Returns
TypeDescription
byte @org.checkerframework.checker.nullness.qual.Nullable []

the image data of the image

getWidth()

public abstract int getWidth()

Gets the width of the image.

Returns
TypeDescription
int

image width

setImageData(byte[] imageData)

public abstract void setImageData(byte[] imageData)

Sets the image to contain the image data contained in imageData.

Parameter
NameDescription
imageDatabyte[]

new image data for the image to store