Interface FileDataSource
-
- All Superinterfaces:
DataSource
- All Known Implementing Classes:
AttachmentDataSource
public interface FileDataSource extends DataSource
Provides type and size information from DataSource
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description longgetSize()Returns the size of the file in bytes.StringgetType()Returns the MIME type of the content.StringgetTypeFromFileName()Returns the MIME type extension from file name.-
Methods inherited from interface javax.activation.DataSource
getContentType, getInputStream, getName, getOutputStream
-
-
-
-
Method Detail
-
getType
String getType()
Returns the MIME type of the content.- Returns:
- content MIME type.
-
getTypeFromFileName
String getTypeFromFileName()
Returns the MIME type extension from file name.- Returns:
- content MIME type extension from file Name.
-
getSize
long getSize()
Returns the size of the file in bytes.- Returns:
- size of file in bytes.
-
-