An image shown for an auction, for example a photo of the item being auctioned. The image bytes are not held here, only the hash of the stored file, so displaying one means reading the hash from the blob store. The orientation field says which shape the image is cropped for, using the ORIENTATION constants on this class, and a null orientation marks the primary image to fall back to. An auction can have several images.
Group: Database Entities
Implements: Serializable
Properties
| Property | Returns | Description |
|---|---|---|
| auction | Auction | The auction this image belongs to. Never null. |
| id | long | Database identifier for this image, assigned when it is first saved. |
| imageHash | String | Hash of the image file in the blob store. The bytes are not on this row, so use the hash to read the image from the content repository. Never null. |
| name | String | File name of the image, used to identify it within the auction. Never null. |
| orientation | String | The shape this image is cropped for, one of the ORIENTATION constants on this class, being square, vertical or horizontal. Null means this is the primary image, used when no image matches the wanted shape. |
Methods
getId()
Returns: long
Database identifier for this image, assigned when it is first saved.
getName()
Returns: String
File name of the image, used to identify it within the auction. Never null.
getAuction()
Returns: Auction
The auction this image belongs to. Never null.
getImageHash()
Returns: String
Hash of the image file in the blob store. The bytes are not on this row, so use the hash to read the image from the content repository. Never null.
getOrientation()
Returns: String
The shape this image is cropped for, one of the ORIENTATION constants on this class, being square, vertical or horizontal. Null means this is the primary image, used when no image matches the wanted shape.