public class XmlFile
extends java.lang.Object
Constructor and Description |
---|
XmlFile()
Instantiates a new xml file.
|
Modifier and Type | Method and Description |
---|---|
void |
addContent(org.jdom2.Element el)
Adds the content.
|
void |
addContent(java.lang.String name,
java.lang.String text)
Adds the content.
|
void |
addRootNode(java.lang.String name)
Adds the root node.
|
org.jdom2.Element |
getNext()
Gets the next.
|
boolean |
hasNextElement()
Checks for next element.
|
void |
openFile(java.lang.String fPath)
Open file.
|
void |
writeToFile(java.lang.String fPath)
Write to file.
|
public void addRootNode(java.lang.String name)
name
- the namepublic void addContent(java.lang.String name, java.lang.String text)
name
- the nametext
- the textpublic void addContent(org.jdom2.Element el)
el
- the elpublic void writeToFile(java.lang.String fPath) throws java.lang.Exception
fPath
- the f pathjava.lang.Exception
- the exceptionpublic void openFile(java.lang.String fPath) throws java.lang.Exception
fPath
- the f pathjava.lang.Exception
- the exceptionpublic boolean hasNextElement()
public org.jdom2.Element getNext()