| java.lang.Object org.griphyn.vdl.euryale.FlatFileFactory org.griphyn.vdl.euryale.HashedFileFactory org.griphyn.vdl.euryale.VirtualDecimalHashedFileFactory
VirtualDecimalHashedFileFactory | public class VirtualDecimalHashedFileFactory extends HashedFileFactory (Code) | | A Virtual Hashed File Factory that does not do any existence checks while
creating a directory. The factory, is used to create remote paths without
checking for correctness.
Additionally, it employs a decimal numbering scheme instead of hexadecimal
used for HashedFileFactory.
author: Karan Vahi version: $Revision: 289 $ |
Method Summary | |
protected File | createDirectory() Creates a directory for the hashed file directory structure on the
submit host. | public String | format(int number) Converts the given integer into hexadecimal notation, using
the given number of digits, prefixing with zeros as necessary.
Parameters: number - is the number to format. | public void | reset() Resets the helper structures after changing layout parameters. | protected void | sanityCheck(File dir) Checks the destination location for existence, if it can
be created, if it is writable etc. |
VirtualDecimalHashedFileFactory | public VirtualDecimalHashedFileFactory(File baseDirectory) throws IOException(Code) | | Constructor: Creates the base directory and employs sanity checks.
Parameters: baseDirectory - is the place where the other dirs are created,and where the DAG file resides. throws: IOException - if the location is not a writable directory,or cannot be created as such. |
VirtualDecimalHashedFileFactory | public VirtualDecimalHashedFileFactory(String baseDirectory) throws IOException(Code) | | Constructor: Creates the directory and employs sanity checks.
Parameters: baseDirectory - is the place where the other dirs are created,and where the DAG file resides. throws: IOException - if the location is not a writable directory,or cannot be created as such. |
VirtualDecimalHashedFileFactory | public VirtualDecimalHashedFileFactory(File baseDirectory, int totalFiles) throws IOException(Code) | | Constructor: Creates the base directory and employs sanity checks.
Parameters: baseDirectory - is the place where the other dirs are created,and where the DAG file resides. Parameters: totalFiles - is the number of files to support, and the numberof times, the virtual constructor is expected to be called. throws: IOException - if the location is not a writable directory,or cannot be created as such. |
VirtualDecimalHashedFileFactory | public VirtualDecimalHashedFileFactory(String baseDirectory, int totalFiles) throws IOException(Code) | | Constructor: Creates the directory and employs sanity checks.
Parameters: baseDirectory - is the place where the other dirs are created,and where the DAG file resides. Parameters: totalFiles - is the number of files to support, and the numberof times, the virtual constructor is expected to be called. throws: IOException - if the location is not a writable directory,or cannot be created as such. |
createDirectory | protected File createDirectory() throws IOException(Code) | | Creates a directory for the hashed file directory structure on the
submit host. It only creates the File with correct path name, however
does not physically create the file.
the File structure to the created directory throws: IOException - the exception. |
format | public String format(int number)(Code) | | Converts the given integer into hexadecimal notation, using
the given number of digits, prefixing with zeros as necessary.
Parameters: number - is the number to format. a string of appropriate length, filled with leading zeros,representing the number hexadecimally. |
reset | public void reset()(Code) | | Resets the helper structures after changing layout parameters. You
will also need to call this function after you invoked the virtual
constructors, but want to change parameter pertaining to the
directory structure. The structured file count will also be reset!
|
sanityCheck | protected void sanityCheck(File dir) throws IOException(Code) | | Checks the destination location for existence, if it can
be created, if it is writable etc. Does no check as it is
virtual.
Parameters: dir - is the new base directory to optionally create |
|
|