net.sf.retrotranslator.transformer
Class FileContainer

java.lang.Object
  extended by net.sf.retrotranslator.transformer.FileContainer
Direct Known Subclasses:
FolderFileContainer, JarFileContainer

abstract class FileContainer
extends java.lang.Object

Author:
Taras Puchko

Field Summary
protected  java.io.File location
           
 
Constructor Summary
protected FileContainer(java.io.File location)
           
 
Method Summary
abstract  boolean containsUpToDate(java.lang.String name, long sourceTime)
           
abstract  void flush(SystemLogger logger)
           
abstract  java.util.Collection<? extends FileEntry> getEntries()
           
 int getFileCount()
           
 java.io.File getLocation()
           
abstract  long lastModified()
           
abstract  void putEntry(java.lang.String name, byte[] contents, boolean modified)
           
protected static byte[] readFully(java.io.InputStream stream, int length)
           
abstract  void removeEntry(java.lang.String name)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

location

protected java.io.File location
Constructor Detail

FileContainer

protected FileContainer(java.io.File location)
Method Detail

getLocation

public java.io.File getLocation()

getEntries

public abstract java.util.Collection<? extends FileEntry> getEntries()

removeEntry

public abstract void removeEntry(java.lang.String name)

putEntry

public abstract void putEntry(java.lang.String name,
                              byte[] contents,
                              boolean modified)

flush

public abstract void flush(SystemLogger logger)

containsUpToDate

public abstract boolean containsUpToDate(java.lang.String name,
                                         long sourceTime)

lastModified

public abstract long lastModified()

readFully

protected static byte[] readFully(java.io.InputStream stream,
                                  int length)
                           throws java.io.IOException
Throws:
java.io.IOException

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

getFileCount

public int getFileCount()