Class Configuration.Attachment
- Enclosing class:
Configuration
A type containing attachment data.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionsetData(byte[] value) The binary content of the attachment.setDescription(String value) The description of the attachment.setMimeType(String value) The MIME type of the attachment.The file name associated with the attachment.IfsetData(byte[])is not set or set tonull, the attachment will be retrieved from this URL.
-
Constructor Details
-
Attachment
public Attachment()
-
-
Method Details
-
setData
The binary content of the attachment. May be
null.- Returns:
- The current
Configuration.Attachmentinstance.
-
setUrl
If
setData(byte[])is not set or set tonull, the attachment will be retrieved from this URL.If this is "#" the input document URL is used instead.
- Returns:
- The current
Configuration.Attachmentinstance.
-
setName
The file name associated with the attachment. It is recommended to specify the correct file extension. If this is not set or
nullthe name is derived fromsetUrl(String).- Returns:
- The current
Configuration.Attachmentinstance.
-
setDescription
The description of the attachment. If this is not set or
nullthe value ofsetName(String)is used.- Returns:
- The current
Configuration.Attachmentinstance.
-
setMimeType
The MIME type of the attachment. If this is not set,
nullor the empty string, detection is attempted or the default valueapplication/octet-streamis used.
Please note that viewers generally ignore the MIME type in favor of the file extension. However, automatic processing of PDF documents may require attachments to have specific MIME types.- Returns:
- The current
Configuration.Attachmentinstance.
-