Package org.ametys.cms.data
Interface File
-
- All Known Implementing Classes:
Binary
,ExplorerFile
public interface File
Class representing a file
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description InputStream
getInputStream()
Returns the data stream.ZonedDateTime
getLastModificationDate()
Returns the last modification date.long
getLength()
Returns the length of the data stream.String
getMimeType()
Returns the data mime-type.String
getName()
Retrieves the file's namevoid
setLastModificationDate(ZonedDateTime lastModificationDate)
Sets the last modification date of the file's datavoid
setMimeType(String mimeType)
Sets the mime type of the file's data
-
-
-
Method Detail
-
getInputStream
InputStream getInputStream()
Returns the data stream.- Returns:
- the data stream.
-
getLastModificationDate
ZonedDateTime getLastModificationDate()
Returns the last modification date.- Returns:
- the last modification date.
-
setLastModificationDate
void setLastModificationDate(ZonedDateTime lastModificationDate)
Sets the last modification date of the file's data- Parameters:
lastModificationDate
- the last modification date to set
-
getLength
long getLength()
Returns the length of the data stream.- Returns:
- the length of the data stream.
-
getMimeType
String getMimeType()
Returns the data mime-type.- Returns:
- the data mime-type.
-
setMimeType
void setMimeType(String mimeType)
Sets the mime type of the file's data- Parameters:
mimeType
- the mime type to set
-
-