bill.util.xml
Class SimpleXML.SimpleXMLBuilder

java.lang.Object
  |
  +--bill.util.xml.SimpleXML.SimpleXMLBuilder
Enclosing class:
SimpleXML

public class SimpleXML.SimpleXMLBuilder
extends Object

This class is used to assist in the creation of a SimpleXML class instance from an XML string. It's instances are only created temporarily during the processing of the XML string, then they are discarded.


Constructor Summary
SimpleXML.SimpleXMLBuilder(String name)
           
 
Method Summary
 void addChild(SimpleXML.SimpleXMLBuilder child)
          Adds a new child object to this object's children list.
 boolean equals(Object other)
          Checks if two SimpleXMLBuilder objects are equal.
 SimpleXML.SimpleXMLBuilder get(SimpleXML.SimpleXMLBuilder builder)
          Finds the specified Builder object in this object's list of children.
 String getName()
          Retrieves the name of this object.
 int getNumOccur()
          Retrieves the number of times the element represented by this object occurs.
 void incrementCount()
          Ups the number of occurrences of this object's element by one.
 void setChildren(Vector children)
          Sets the list of children to the specified value.
 void setName(String name)
          Sets the name of this object.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleXML.SimpleXMLBuilder

public SimpleXML.SimpleXMLBuilder(String name)
Method Detail

getName

public String getName()
Retrieves the name of this object.
Returns:
The name of this object.

setName

public void setName(String name)
Sets the name of this object.
Parameters:
name - The new name of this object.

getNumOccur

public int getNumOccur()
Retrieves the number of times the element represented by this object occurs.
Returns:
The number of times the element occurs.

incrementCount

public void incrementCount()
Ups the number of occurrences of this object's element by one.

get

public SimpleXML.SimpleXMLBuilder get(SimpleXML.SimpleXMLBuilder builder)
Finds the specified Builder object in this object's list of children.
Parameters:
builder - The builder object to find.
Returns:
Returns the found builder object, or nul if no match was found.

addChild

public void addChild(SimpleXML.SimpleXMLBuilder child)
Adds a new child object to this object's children list.
Parameters:
child - The new child object to add to the list.

setChildren

public void setChildren(Vector children)
Sets the list of children to the specified value.
Parameters:
children - The new list of children.

equals

public boolean equals(Object other)
Checks if two SimpleXMLBuilder objects are equal. They are concidered equal if their names match.
Overrides:
equals in class Object
Parameters:
other - The other object to check for equality.
Returns:
Returns true if the object are equal, returns false otherwise.