DLESE Tools
v1.6.0

org.dlese.dpc.xml.schema
Class SchemaNodeMap

java.lang.Object
  extended by org.dlese.dpc.xml.schema.SchemaNodeMap

public class SchemaNodeMap
extends Object

Map structure holding SchemaNode instances, keyed by XPaths to the Nodes.

All Nodes (Elements & Attributes) defined by the Schema will be represented in the SchemaNodeMap. The keys of the SchemaNodeMap are normalized in the sense that there is only one entry for a repeating element (i.e., no Xpath key will contain indexing).

Author:
ostwald


Nested Class Summary
 class SchemaNodeMap.DocOrderComparator
          Comparator to sort the keyMap in document order.
 
Constructor Summary
SchemaNodeMap()
          Constructor for the SchemaNodeMap object
 
Method Summary
 boolean containsKey(String key)
          Description of the Method
 void destroy()
          Should release resources and call the finalize method.
 List getKeys()
          Method to retrieve the list of names used to identify desired values.
 List getKeys(short nodeType)
          Method to retrieve the list of names used to identify desired values of a particular type.
 Object getValue(String path)
          Accessor method for retrieving a specific named GlobalDef.
 List getValues()
          Method to retrieve the list of values stored in this map.
 boolean init()
          Should initialize members as required.
static void setDebug(boolean d)
          Sets the debug attribute of the SchemaNodeMap class
 void setMap()
          Use this method to populate the XMLMap with the desired named values.
 void setValue(String path, SchemaNode schemaNode)
          Setter method for updating a specific named value.
 String toString()
          Description of the Method
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SchemaNodeMap

public SchemaNodeMap()
Constructor for the SchemaNodeMap object

Method Detail

init

public boolean init()
Should initialize members as required.

Returns:
true if intialization successful, false otherwise

destroy

public void destroy()
Should release resources and call the finalize method.


setMap

public void setMap()
Use this method to populate the XMLMap with the desired named values.


getKeys

public List getKeys()
Method to retrieve the list of names used to identify desired values.

Returns:
The keys value

containsKey

public boolean containsKey(String key)
Description of the Method

Parameters:
key - Description of the Parameter
Returns:
Description of the Return Value

getKeys

public List getKeys(short nodeType)
Method to retrieve the list of names used to identify desired values of a particular type.

Parameters:
nodeType - Description of the Parameter
Returns:
The keys value

getValues

public List getValues()
Method to retrieve the list of values stored in this map.

Returns:
The values value

getValue

public Object getValue(String path)
Accessor method for retrieving a specific named GlobalDef.

Parameters:
path - Description of the Parameter
Returns:
The value value

setValue

public void setValue(String path,
                     SchemaNode schemaNode)
Setter method for updating a specific named value.

Parameters:
path - The new value value
schemaNode - The new value value

toString

public String toString()
Description of the Method

Overrides:
toString in class Object
Returns:
Description of the Return Value

setDebug

public static void setDebug(boolean d)
Sets the debug attribute of the SchemaNodeMap class

Parameters:
d - The new debug value

DLESE Tools
v1.6.0