A file attached to a product order, such as a proof, an artwork file or a receipt image. The file content itself is not stored on the row; only the hash of the stored blob is held, so reading the bytes means looking the hash up in the blob store. Each attachment records a MIME content type and a disposition, and the disposition decides whether the file is sent as a normal attachment or embedded inline when the order is emailed out.

Group: Database Entities

Implements: Serializable


Properties

PropertyReturnsDescription
contentTypeStringMIME content type of the attached file, for example image/png or application/pdf. Used when the file is added to an outgoing message or served for download.
dispositionStringMIME disposition to use when this file is added to a message, normally attachment or inline. Inline files are embedded in the message body, attachments are sent as separate parts.
fileHashStringHash of the file content in the blob store. The bytes are not held on this row, so use the hash to read the file from the content repository.
idlongDatabase identifier for this attachment, assigned when it is first saved.
nameStringFile name for the attachment, as it appears when the order is emailed or the file is downloaded.
productOrderProductOrderThe order this file is attached to. Never null, an attachment cannot exist on its own.

Methods

getId()

Returns: long

Database identifier for this attachment, assigned when it is first saved.

getProductOrder()

Returns: ProductOrder

The order this file is attached to. Never null, an attachment cannot exist on its own.

getName()

Returns: String

File name for the attachment, as it appears when the order is emailed or the file is downloaded.

getFileHash()

Returns: String

Hash of the file content in the blob store. The bytes are not held on this row, so use the hash to read the file from the content repository.

getContentType()

Returns: String

MIME content type of the attached file, for example image/png or application/pdf. Used when the file is added to an outgoing message or served for download.

getDisposition()

Returns: String

MIME disposition to use when this file is added to a message, normally attachment or inline. Inline files are embedded in the message body, attachments are sent as separate parts.

To get full access to the Kademi Hub existing customers can login here, or new customers can register here.