org.jmonks.batch.io
Class FileType

java.lang.Object
  extended byorg.jmonks.batch.io.FileType

public final class FileType
extends java.lang.Object

FileType defines different kinds of file formats this package supports for reading and writing. This defines the constants to identify those file formats that it supports as enums. The file type information should be provided when defining the file spec to identify the kind of file this spec is going to represent.

Since:
1.0
Version:
1.0
Author:
Suresh Pragada

Field Summary
static FileType DELIMITED_FLAT_FILE
          Represents the delimited flat files.
static FileType FIXED_WIDTH_FLAT_FILE
          Represents the fixed width flat files.
static FileType XML_FILE
          Represents the xml files.
 
Method Summary
static FileType toFileType(java.lang.String type)
          Utility method returns the FileType object matches to the given value.
 java.lang.String toString()
          Returns the string representation of the FileType which can be used to defines the file spec.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

FIXED_WIDTH_FLAT_FILE

public static final FileType FIXED_WIDTH_FLAT_FILE
Represents the fixed width flat files. The value to be used in the file spec for this kind of file types is "fixed-width-flat".


DELIMITED_FLAT_FILE

public static final FileType DELIMITED_FLAT_FILE
Represents the delimited flat files. The value to be used in the file spec for this kind of file types is "delimited-flat".


XML_FILE

public static final FileType XML_FILE
Represents the xml files. The value to be used in the file spec for this kind of file types is "xml".

Method Detail

toFileType

public static FileType toFileType(java.lang.String type)
Utility method returns the FileType object matches to the given value.

Parameters:
type - String representing the type of file.
Returns:
Returns the FileType references matches to the given values, null if it cannot match to the available file types.

toString

public java.lang.String toString()
Returns the string representation of the FileType which can be used to defines the file spec.