API Overview API Index Package Overview Direct link to this page
JDK 1.6
  javax.activation. FileDataSource View Source
Author(s)
Since
1.6
Version
Serial
Hierarchy
 Object
      FileDataSource
Implements
 DataSource
Subclasses
Description
public class FileDataSource
  The FileDataSource class implements a simple DataSource object that encapsulates a file.
Constructors
public FileDataSource (File file)
  Creates a FileDataSource from a File object.
public FileDataSource (String name)
  Creates a FileDataSource from the specified path name.
Methods
Hide/Show inherited methods
public String getContentType () [Specified in DataSource]
  This method returns the MIME type of the data in the form of a string.
public File getFile ()
  Return the File object that corresponds to this FileDataSource.
public InputStream getInputStream () throws IOException [Specified in DataSource]
  This method will return an InputStream representing the the data and will throw an IOException if it can not do so.
public String getName () [Specified in DataSource]
  Return the name of this object.
public OutputStream getOutputStream () throws IOException [Specified in DataSource]
  This method will return an OutputStream representing the the data and will throw an IOException if it can not do so.
public void setFileTypeMap (FileTypeMap map)
  Set the FileTypeMap to use with this FileDataSource
Fields
Hide/Show inherited fields
Nested Classes
Generated By: JavaOnTracks Doclet 0.1.4     ©Thibaut Colar