XML for Java Compatibility API 2.0.11

com.ibm.xml.parser
Class CM1op

java.lang.Object
  |
  +--com.ibm.xml.parser.CMNode
        |
        +--com.ibm.xml.parser.CM1op

public class CM1op
extends CMNode

CM1op provides content model support for content model nodes that contain the "*", "?", and "+" language primitives. Refer to ElementDecl for an overview of the content model, and how these language primitives are used to express relationships.

Version:
Revision: 57 1.5 src/com/ibm/xml/parser/CM1op.java, parser, xml4j2, xml4j2_0_11
See Also:
ElementDecl, CMNode, CMLeaf, Serialized Form

Constructor Summary
CM1op(int type, CMNode node)
          Constructor.
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 CMNode getNode()
          Returns the content model node associated with type.
 int getType()
          Returns the language primitive associated with this content model node.
 int hashCode()
           
 void setNode(CMNode node)
          Sets the content model node associated with type.
 java.lang.String toString()
          Returns the string representation of this content model node and its associated language primitive.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CM1op

public CM1op(int type,
             CMNode node)
Constructor.
Parameters:
type - The language primitive associated with this content model node. Must be "*", "?", or "+".
node - The content model node to associate with type, or null if node will be set later.
Method Detail

getType

public int getType()
Returns the language primitive associated with this content model node.
Returns:
"*", "?", or "+" (should never be null).

getNode

public CMNode getNode()
Returns the content model node associated with type.
Returns:
The content model node associated with type, or null if no node currently exists.
See Also:
setNode(com.ibm.xml.parser.CMNode)

setNode

public void setNode(CMNode node)
Sets the content model node associated with type.
Parameters:
node - The content model node to associate with type.
See Also:
getNode()

toString

public java.lang.String toString()
Returns the string representation of this content model node and its associated language primitive. Example: elementX*
Returns:
The string representation of this content model node (should never be null).
Overrides:
toString in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

XML for Java Compatibility API 2.0.11