|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.bsd.x2svg.parsers.BuildXmlParser
public class BuildXmlParser
Field Summary | |
---|---|
private org.w3c.dom.Document |
doc
|
private static java.lang.String |
FILE_SUFFIX_STRING
|
private boolean |
forest
|
private java.io.File |
inputFile
|
private static java.lang.String |
MODE_STRING
|
private java.lang.String |
rootElement
|
Constructor Summary | |
---|---|
BuildXmlParser()
|
Method Summary | |
---|---|
private void |
findChildren(java.lang.String rootName,
Container rootCont)
Find the children of the target with name rootName and fill them into the passed container. |
java.lang.String |
getFileSuffix()
Out suffix is 'build.xml' - whole string |
java.lang.String |
getMode()
Our mode is 'ant' |
java.lang.String |
getSpecificHelp()
Return a String that gives help for this specific parser. |
private org.w3c.dom.Element |
getTargetByName(java.lang.String rootName)
Get a <target> by its 'name' attribute |
Container |
parseInput()
Parse the passed build file. |
void |
setDebug()
Tells the parer to set the debug mode. |
void |
setInputFile(java.io.File inputFile)
Sets the input file to work on |
void |
setParserOptions(java.lang.String[] options)
Pass in options to this parser. |
void |
setWithAttributes(boolean value)
Tells the parser that parsing attributes of elements is wanted. |
void |
setWithElementComments(boolean value)
Tells the parser that parsing comments for elements (and possibly attributes) is desired. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final java.lang.String MODE_STRING
private static final java.lang.String FILE_SUFFIX_STRING
private java.io.File inputFile
private org.w3c.dom.Document doc
private boolean forest
private java.lang.String rootElement
Constructor Detail |
---|
public BuildXmlParser()
Method Detail |
---|
public Container parseInput() throws java.lang.Exception
parseInput
in interface InputParser
java.lang.Exception
- if anything goes wrong.Container
private void findChildren(java.lang.String rootName, Container rootCont) throws ParserProblemException
rootName
- Name of the <target> to work onrootCont
- The container to fill with children.
ParserProblemException
- If a target with the passed name can not be found.private org.w3c.dom.Element getTargetByName(java.lang.String rootName)
rootName
- the name to look for
public void setInputFile(java.io.File inputFile)
setInputFile
in interface InputParser
inputFile
- a vaild file object to work onpublic void setParserOptions(java.lang.String[] options)
setParserOptions
in interface InputParser
options
- array of individual option parts as passed on the command line.public java.lang.String getSpecificHelp()
InputParser
getSpecificHelp
in interface InputParser
public java.lang.String getFileSuffix()
getFileSuffix
in interface InputParser
public java.lang.String getMode()
getMode
in interface InputParser
public void setDebug()
InputParser
setDebug
in interface InputParser
public void setWithAttributes(boolean value)
InputParser
DtdParser
is able to do this, while the PropertiesParser
is not.
setWithAttributes
in interface InputParser
value
- The value to set this to.public void setWithElementComments(boolean value)
InputParser
setWithElementComments
in interface InputParser
value
- The value to set this to.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |