org.blinkenlights.jid3.io
Class FileSource

java.lang.Object
  extended byorg.blinkenlights.jid3.io.FileSource
All Implemented Interfaces:
IFileSource

public class FileSource
extends java.lang.Object
implements IFileSource

A concrete implementation of the IFileSource interface, allowing access to standard java.io.File objects.


Constructor Summary
FileSource(java.io.File oFile)
          Creates a new instance of FileSource
 
Method Summary
 IFileSource createTempFile(java.lang.String sPrefix, java.lang.String sSuffix)
           
 boolean delete()
           
 java.io.InputStream getInputStream()
           
 java.lang.String getName()
           
 java.io.OutputStream getOutputStream()
           
 long length()
           
 boolean renameTo(IFileSource oFileSource)
           
 boolean renameTo(java.lang.String sFilename)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FileSource

public FileSource(java.io.File oFile)
Creates a new instance of FileSource

Method Detail

createTempFile

public IFileSource createTempFile(java.lang.String sPrefix,
                                  java.lang.String sSuffix)
                           throws java.io.IOException
Specified by:
createTempFile in interface IFileSource
Throws:
java.io.IOException

delete

public boolean delete()
Specified by:
delete in interface IFileSource

getName

public java.lang.String getName()
Specified by:
getName in interface IFileSource

getInputStream

public java.io.InputStream getInputStream()
                                   throws java.io.FileNotFoundException
Specified by:
getInputStream in interface IFileSource
Throws:
java.io.FileNotFoundException

getOutputStream

public java.io.OutputStream getOutputStream()
                                     throws java.io.FileNotFoundException
Specified by:
getOutputStream in interface IFileSource
Throws:
java.io.FileNotFoundException

length

public long length()
Specified by:
length in interface IFileSource

renameTo

public boolean renameTo(java.lang.String sFilename)

renameTo

public boolean renameTo(IFileSource oFileSource)
                 throws java.io.IOException
Specified by:
renameTo in interface IFileSource
Throws:
java.io.IOException

toString

public java.lang.String toString()
Specified by:
toString in interface IFileSource