net.sf.jpkgmk
Class DefaultFileHandler

java.lang.Object
  extended by net.sf.jpkgmk.DefaultFileHandler
All Implemented Interfaces:
FileHandler

public class DefaultFileHandler
extends java.lang.Object
implements FileHandler

Default implementation of FileHandler.

Since:
1.0
Version:
$Revision: 2 $ $Date: 2008-08-20 21:14:19 +0200 (Mi, 20 Aug 2008) $
Author:
gommma (gommma AT users.sourceforge.net), Last changed by: $Author: gommma $

Nested Class Summary
 
Nested classes/interfaces inherited from interface net.sf.jpkgmk.FileHandler
FileHandler.ContentWriter
 
Constructor Summary
DefaultFileHandler(java.io.File basedir, java.lang.String filename)
           
 
Method Summary
 void clean()
          Removes the file that can be retrieved via FileHandler.getFile()
 void create(FileHandler.ContentWriter contentWriter)
          Creates the file that can be retrieved via FileHandler.getFile()
 java.io.File getBasedir()
           
 java.io.File getFile()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DefaultFileHandler

public DefaultFileHandler(java.io.File basedir,
                          java.lang.String filename)
Parameters:
basedir - The directory where the file should be created.
filename -
Method Detail

getBasedir

public java.io.File getBasedir()

getFile

public java.io.File getFile()
Specified by:
getFile in interface FileHandler
Returns:
The file to be created

create

public void create(FileHandler.ContentWriter contentWriter)
            throws java.io.IOException
Description copied from interface: FileHandler
Creates the file that can be retrieved via FileHandler.getFile()

Specified by:
create in interface FileHandler
Throws:
java.io.IOException

clean

public void clean()
Description copied from interface: FileHandler
Removes the file that can be retrieved via FileHandler.getFile()

Specified by:
clean in interface FileHandler
See Also:
FileHandler.clean()

toString

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


Copyright © 2007-2008. All Rights Reserved.