XML
Class XMLLoader

java.lang.Object
  |
  +--XML.XMLLoader

public class XMLLoader
extends java.lang.Object

This class can restore the state of the program from an XML file. It also provides methods which XMLSerializable objects can use to retrieve their child objects.


Field Summary
protected  XMLElement currentElement
           
protected  XMLElement nextElement
           
protected  XML.XMLReader reader
           
 
Constructor Summary
XMLLoader(java.io.File file)
          Make a new XMLLoader which loads from a file
 
Method Summary
 void close()
           
 java.lang.String getNextElementName()
           
 void loadObject(XMLSerializable object)
           
 void moveOnOne()
           
 XMLElement parse(java.lang.String string)
          Parse a new XML element from a string which contains a XML tag
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

reader

protected XML.XMLReader reader

currentElement

protected XMLElement currentElement

nextElement

protected XMLElement nextElement
Constructor Detail

XMLLoader

public XMLLoader(java.io.File file)
          throws java.io.IOException
Make a new XMLLoader which loads from a file

Parameters:
file - The file to load from
Throws:
java.io.IOException - If the XMLLoader cannot read from the XML file because of an IO error.
Method Detail

loadObject

public void loadObject(XMLSerializable object)

close

public void close()

getNextElementName

public java.lang.String getNextElementName()

moveOnOne

public void moveOnOne()

parse

public XMLElement parse(java.lang.String string)
Parse a new XML element from a string which contains a XML tag

Parameters:
string - The string to parse