|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.torque.generator.source.SourceImpl org.apache.torque.generator.source.stream.FileSource
public class FileSource
A Source which uses a file as input.
Constructor Summary | |
---|---|
FileSource(StreamSourceFormat format,
File path,
ControllerState controllerState)
Constructor. |
Method Summary | |
---|---|
SourceElement |
createRootElement()
Reads and parses the input file and creates the element tree from it. |
String |
getDescription()
Returns the path of the file as a description. |
File |
getPath()
Returns the path to the source file. |
File |
getSourceFile()
Returns the source file, if it exists. |
StreamSourceFormat |
getSourceFormat()
Returns the format of the source. |
String |
toString()
|
Methods inherited from class org.apache.torque.generator.source.SourceImpl |
---|
getRootElement |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public FileSource(StreamSourceFormat format, File path, ControllerState controllerState)
format
- the source format, not null.path
- the path to the file to read, not null.ControllerState
- the controller state, not null.
NullPointerException
- if path or format is null.Method Detail |
---|
public StreamSourceFormat getSourceFormat()
public File getPath()
public SourceElement createRootElement() throws SourceException
createRootElement
in class SourceImpl
SourceException
- if the input file cannot be read or parsed.public String getDescription()
Source.getDescription()
public File getSourceFile()
public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |