Package io.qameta.allure
Class AttachmentOptions
java.lang.Object
io.qameta.allure.AttachmentOptions
Additional options for an attachment.
When file extension is not set, it will be detected from the attachment content type when possible. Use an empty string as file extension to force no extension.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic AttachmentOptionsempty()Creates empty attachment options.Gets attachment file extension.setFileExtension(String fileExtension) Sets attachment file extension.static AttachmentOptionswithFileExtension(String fileExtension) Creates attachment options with the file extension.
-
Constructor Details
-
AttachmentOptions
public AttachmentOptions()
-
-
Method Details
-
empty
Creates empty attachment options. The file extension will be detected from the attachment content type when possible.- Returns:
- empty attachment options
-
withFileExtension
Creates attachment options with the file extension.- Parameters:
fileExtension- the attachment file extension- Returns:
- attachment options
-
getFileExtension
Gets attachment file extension.- Returns:
- attachment file extension
-
setFileExtension
Sets attachment file extension. Usenullto detect the extension from the attachment content type when possible, or an empty string to force no extension.- Parameters:
fileExtension- the attachment file extension- Returns:
- this instance for method chaining
-