org.openxri.xml
Class SimpleXMLElement

java.lang.Object
  extended by org.openxri.xml.SimpleXMLElement
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable
Direct Known Subclasses:
CanonicalEquivID, CanonicalID, EquivID, Expires, LocalID, ProviderID, Query, Redirect, Ref, ServerStatus, Status, XRDType

public abstract class SimpleXMLElement
extends java.lang.Object
implements java.lang.Cloneable, java.io.Serializable

See Also:
Serialized Form

Field Summary
protected  java.util.Hashtable attributes
           
 
Constructor Summary
SimpleXMLElement(SimpleXMLElement s)
           
SimpleXMLElement(java.lang.String tagname)
          Creates a SimpleXMLElement object with the given tagname
SimpleXMLElement(java.lang.String tagname, java.lang.String sValue)
           
 
Method Summary
 void addAttribute(java.lang.String attrName, java.lang.String attrValue)
           
 java.lang.Object clone()
           
 boolean equals(java.lang.Object o)
           
 void fromXML(org.w3c.dom.Node root)
          Sets the members of this EppXriServiceEndpointRule object from the given XML element.
 java.lang.String getAttributeValue(java.lang.String attrName)
           
 java.lang.String getTagname()
           
 java.lang.String getValue()
          Gets the value of this Type/MediaType/Path rule
 int hashCode()
           
 void removeAttribute(java.lang.String attrName)
           
protected  void reset(java.lang.String tagName)
           
 void setValue(java.lang.String value)
          Sets the value of this Type/MediaType/Path rule
 java.lang.String toString()
           
protected  java.lang.String toString(java.lang.String tag)
           
 org.w3c.dom.Element toXML(org.w3c.dom.Document doc)
           
 org.w3c.dom.Element toXML(org.w3c.dom.Document doc, java.lang.String tag)
          Converts the EppXriServiceEndpointRule object into an XML element
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

attributes

protected java.util.Hashtable attributes
Constructor Detail

SimpleXMLElement

public SimpleXMLElement(SimpleXMLElement s)

SimpleXMLElement

public SimpleXMLElement(java.lang.String tagname)
Creates a SimpleXMLElement object with the given tagname

Parameters:
tagname -

SimpleXMLElement

public SimpleXMLElement(java.lang.String tagname,
                        java.lang.String sValue)
Method Detail

reset

protected void reset(java.lang.String tagName)

getTagname

public java.lang.String getTagname()

getValue

public java.lang.String getValue()
Gets the value of this Type/MediaType/Path rule


setValue

public void setValue(java.lang.String value)
Sets the value of this Type/MediaType/Path rule


addAttribute

public void addAttribute(java.lang.String attrName,
                         java.lang.String attrValue)

getAttributeValue

public java.lang.String getAttributeValue(java.lang.String attrName)

removeAttribute

public void removeAttribute(java.lang.String attrName)

toXML

public org.w3c.dom.Element toXML(org.w3c.dom.Document doc,
                                 java.lang.String tag)
Converts the EppXriServiceEndpointRule object into an XML element

Parameters:
doc - the XML Document object
tag - the tag/element name for the EppXriServiceEndpoint object
Returns:
an Element object

toXML

public org.w3c.dom.Element toXML(org.w3c.dom.Document doc)

fromXML

public void fromXML(org.w3c.dom.Node root)
Sets the members of this EppXriServiceEndpointRule object from the given XML element. The caller of this method must make sure that the root node is of the EPP XRI sepRuleType.

Parameters:
root - root node for an EppXriServiceEndpointRule object in XML format

toString

protected java.lang.String toString(java.lang.String tag)

clone

public java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Overrides:
clone in class java.lang.Object
Throws:
java.lang.CloneNotSupportedException

equals

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

hashCode

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

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2005-2012. All Rights Reserved.