org.gswing.utils.xml
Class XmlWriter
java.lang.Object
org.gswing.utils.xml.XmlReader
org.gswing.utils.xml.XmlWriter
- Direct Known Subclasses:
- DbXmlWriter, ElectionsToXml, PartiesToXml
public class XmlWriter
- extends XmlReader
Purpose: Generic XML writer. When an XML writer has been created, use the
getDocument() method to get the root document to add elements. When all
elements have been added use writeToFile to write data to the XML file.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XmlWriter
public XmlWriter(File file)
- Constructor.
- Parameters:
file
- The XML file to read.
writeToFile
public boolean writeToFile()
- Write XML document to XML file.
- Returns:
- True if the file was written successfully.
getNewDocument
public Document getNewDocument()
- Create a new XML document object.
- Returns:
- A new XML document object.
Copyright © 2008. All Rights Reserved.