Interface SearchableAttachment
-
- All Superinterfaces:
Searchable
- All Known Implementing Classes:
Attachment
public interface SearchableAttachment extends Searchable
An object representing some searchable file.- Since:
- 8.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description String
getComment()
Return any comment associated with this attachmentInputStream
getContentsAsStream()
Return the contents of the attachment as an InputStreamString
getContentType()
Gets the MIME content-type of this attachment.String
getDownloadPath()
String
getFileName()
Gets the filename of this attachment.String
getNiceFileSize()
String
getNiceType()
-
Methods inherited from interface com.atlassian.bonnie.Searchable
getId, getSearchableDependants, isIndexable
-
-
-
-
Method Detail
-
getContentType
String getContentType()
Gets the MIME content-type of this attachment. If there is no content-type, return "application/x-unknown". Should never return null.- Returns:
- the MIME content-type of the attachment, or "application/x-unknown" if the MIME type is unknown
-
getFileName
String getFileName()
Gets the filename of this attachment. If there is no filename, return the empty string. This method should never return null.- Returns:
- the filename of this attachment, or the empty string if there is no filename
-
getContentsAsStream
InputStream getContentsAsStream() throws IOException
Return the contents of the attachment as an InputStream- Returns:
- an InputStream set at the start of the attachment's contents.
- Throws:
IOException
-
getComment
String getComment()
Return any comment associated with this attachment
-
getNiceType
String getNiceType()
-
getNiceFileSize
String getNiceFileSize()
-
getDownloadPath
String getDownloadPath()
-
-