--- projects/cms/source/util/uk/org/iscream/cms/util/XMLStringParser.java 2001/03/10 02:03:55 1.9 +++ projects/cms/source/util/uk/org/iscream/cms/util/XMLStringParser.java 2001/03/10 04:03:52 1.10 @@ -4,18 +4,15 @@ package uk.ac.ukc.iscream.util; //---IMPORTS--- import java.io.*; import java.util.ArrayList; - import org.xml.sax.*; import org.xml.sax.helpers.*; -import javax.xml.parsers.SAXParserFactory; -import javax.xml.parsers.ParserConfigurationException; -import javax.xml.parsers.SAXParser; +import javax.xml.parsers.*; /** * XMLStringParser - Used to assist in creating XMLPacket objects. * * @author $Author: tdb $ - * @version $Id: XMLStringParser.java,v 1.9 2001/03/10 02:03:55 tdb Exp $ + * @version $Id: XMLStringParser.java,v 1.10 2001/03/10 04:03:52 tdb Exp $ */ public class XMLStringParser extends DefaultHandler { @@ -24,7 +21,7 @@ public class XMLStringParser extends DefaultHandler { /** * The current CVS revision of this class */ - public final String REVISION = "$Revision: 1.9 $"; + public final String REVISION = "$Revision: 1.10 $"; //---STATIC METHODS--- @@ -46,13 +43,6 @@ public class XMLStringParser extends DefaultHandler { //---PUBLIC METHODS--- - /** - * Accessor to the XMLPacket. - */ - public XMLPacket getXMLPacket() { - return _packet; - } - //=========================================================== // SAX DocumentHandler methods //=========================================================== @@ -76,7 +66,7 @@ public class XMLStringParser extends DefaultHandler { } } } - + /** * When an XML element is finished with, we must remove * the tag name from the tagList and decrement the indent @@ -86,8 +76,7 @@ public class XMLStringParser extends DefaultHandler { _tagList.remove(_tagList.size() - 1); _indentLevel--; } - - + /** * Any text falling within a pair of terminal tags must * be added to the XMLPacket. Trim leading and trailing @@ -136,6 +125,13 @@ public class XMLStringParser extends DefaultHandler { } //---ACCESSOR/MUTATOR METHODS--- + + /** + * Accessor to the XMLPacket. + */ + public XMLPacket getXMLPacket() { + return _packet; + } //---ATTRIBUTES---