org.systinet.wasp.addressing
Class ReferenceProperties

java.lang.Object
  extended byorg.systinet.wasp.addressing.ReferenceProperties
All Implemented Interfaces:
java.io.Externalizable, Node, org.systinet.wasp.addressing.ReferencePropertiesInternal, java.io.Serializable, SOAPElement

public class ReferenceProperties
extends java.lang.Object
implements SOAPElement, java.io.Externalizable, org.systinet.wasp.addressing.ReferencePropertiesInternal

WS-Addressing wsa:ReferenceProperties implementation (an element of wsa:EndpointReference)

API inherited from SOAPElement can be used for setting properties. However, some methods are not supported, see methods javadoc.

Since:
5.5
See Also:
Serialized Form
Component:
Core

Field Summary
static java.lang.String LOCAL_NAME
           
 
Fields inherited from interface org.systinet.wasp.addressing.ReferencePropertiesInternal
NAMESPACE_URI_INTERNAL
 
Constructor Summary
ReferenceProperties()
          Constructs new empty ReferenceProperties
 
Method Summary
 SOAPElement addAttribute(Name name, java.lang.String value)
          Not supported, always throws UnsupportedOperationException
 SOAPElement addChildElement(Name name)
          Creates a new SOAPElement object initialized with the given Name object and adds the new element to this SOAPElement object.
 SOAPElement addChildElement(SOAPElement element)
          Add a SOAPElement as a child of this SOAPElement instance.
 SOAPElement addChildElement(java.lang.String localName)
          Creates a new SOAPElement object initialized with the given String object and adds the new element to this SOAPElement object.
 SOAPElement addChildElement(java.lang.String localName, java.lang.String prefix)
          Creates a new SOAPElement object initialized with the specified local name and prefix and adds the new element to this SOAPElement object.
 SOAPElement addChildElement(java.lang.String localName, java.lang.String prefix, java.lang.String uri)
          Creates a new SOAPElement object initialized with the specified local name, prefix, and URI and adds the new element to this SOAPElement object.
 SOAPElement addNamespaceDeclaration(java.lang.String prefix, java.lang.String uri)
          Not supported, always throws UnsupportedOperationException
 SOAPElement addTextNode(java.lang.String text)
          Not supported, always throws UnsupportedOperationException
 void detachNode()
          Not supported, always throws UnsupportedOperationException
 boolean equals(java.lang.Object o)
          Current implementation checks if the set of Names under root element is the same and only if their subnodes are text nodes, their values are also compared.
 java.util.Iterator getAllAttributes()
          Returns an iterator over all of the attribute names in this SOAPElement object.
 java.lang.String getAttributeValue(Name name)
          Returns the value of the attribute with the specified name.
 java.util.Iterator getChildElements()
          Returns an iterator over all the immediate content of this element.
 java.util.Iterator getChildElements(Name name)
          Returns an iterator over all the child elements with the specified name.
 javax.xml.transform.Source getContent()
          Return source
 Name getElementName()
          Not supported, always throws UnsupportedOperationException
 java.lang.String getEncodingStyle()
          Returns the encoding style for this SOAPElement object.
 SOAPElement getInternalSOAPElement()
           
 java.util.Iterator getNamespacePrefixes()
          Not supported, always throws UnsupportedOperationException
 java.lang.String getNamespaceURI(java.lang.String prefix)
          Not supported, always throws UnsupportedOperationException
 SOAPElement getParentElement()
          Not supported, always throws UnsupportedOperationException
 java.lang.String getValue()
          Returns the the value of the immediate child of this Node object if a child exists and its value is text.
 int hashCode()
           
 void readExternal(java.io.ObjectInput in)
          * Current implementation deserializes a String created from this instance
 void recycleNode()
          Notifies the implementation that this Node object is no longer being used by the application and that the implementation is free to reuse this object for nodes that may be created later.
 boolean removeAttribute(Name name)
          Not supported, always throws UnsupportedOperationException
 boolean removeNamespaceDeclaration(java.lang.String prefix)
          Not supported, always throws UnsupportedOperationException
 void setContent(javax.xml.transform.Source source)
          Set content from specified Source.
 void setEncodingStyle(java.lang.String encodingStyle)
          Sets the encoding style for this SOAPElement object to one specified.
 void setInternalSOAPElement(SOAPElement element)
           
 void setParentElement(SOAPElement parent)
          Not supported, always throws UnsupportedOperationException
 void writeExternal(java.io.ObjectOutput out)
          Current implementation serializes a String created from this instance
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOCAL_NAME

public static final java.lang.String LOCAL_NAME
See Also:
Constant Field Values
Constructor Detail

ReferenceProperties

public ReferenceProperties()
                    throws SOAPException
Constructs new empty ReferenceProperties

Throws:
SOAPException
Method Detail

equals

public boolean equals(java.lang.Object o)
Current implementation checks if the set of Names under root element is the same and only if their subnodes are text nodes, their values are also compared. Also namespace of element is compared

Parameters:
o -
Returns:

hashCode

public int hashCode()

addChildElement

public SOAPElement addChildElement(Name name)
                            throws SOAPException
Description copied from interface: SOAPElement
Creates a new SOAPElement object initialized with the given Name object and adds the new element to this SOAPElement object.

Specified by:
addChildElement in interface SOAPElement
Parameters:
name - a Name object with the XML name for the new element
Returns:
the new SOAPElement object that was created
Throws:
SOAPException - if there is an error in creating the SOAPElement object

addChildElement

public SOAPElement addChildElement(java.lang.String localName)
                            throws SOAPException
Description copied from interface: SOAPElement
Creates a new SOAPElement object initialized with the given String object and adds the new element to this SOAPElement object.

Specified by:
addChildElement in interface SOAPElement
Parameters:
localName - a String giving the local name for the element
Returns:
the new SOAPElement object that was created
Throws:
SOAPException - if there is an error in creating the SOAPElement object

addChildElement

public SOAPElement addChildElement(java.lang.String localName,
                                   java.lang.String prefix)
                            throws SOAPException
Description copied from interface: SOAPElement
Creates a new SOAPElement object initialized with the specified local name and prefix and adds the new element to this SOAPElement object.

Specified by:
addChildElement in interface SOAPElement
Parameters:
localName - a String giving the local name for the new element
prefix - a String giving the namespace prefix for the new element
Returns:
the new SOAPElement object that was created
Throws:
SOAPException - if there is an error in creating the SOAPElement object

addChildElement

public SOAPElement addChildElement(java.lang.String localName,
                                   java.lang.String prefix,
                                   java.lang.String uri)
                            throws SOAPException
Description copied from interface: SOAPElement
Creates a new SOAPElement object initialized with the specified local name, prefix, and URI and adds the new element to this SOAPElement object.

Specified by:
addChildElement in interface SOAPElement
Parameters:
localName - a String giving the local name for the new element
prefix - a String giving the namespace prefix for the new element
uri - a String giving the URI of the namespace to which the new element belongs
Returns:
the new SOAPElement object that was created
Throws:
SOAPException - if there is an error in creating the SOAPElement object

addChildElement

public SOAPElement addChildElement(SOAPElement element)
                            throws SOAPException
Description copied from interface: SOAPElement
Add a SOAPElement as a child of this SOAPElement instance. The SOAPElement is expected to be created by a SOAPElementFactory. Callers should not rely on the element instance being added as is into the XML tree. Implementations could end up copying the content of the SOAPElement passed into an instance of a different SOAPElement implementation. For instance if addChildElement() is called on a SOAPHeader, element will be copied into an instance of a SOAPHeaderElement.

The fragment rooted in element is either added as a whole or not at all, if there was an error.

The fragment rooted in element cannot contain elements named "Envelope", "Header" or "Body" and in the SOAP namespace. Any namespace prefixes present in the fragment should be fully resolved using appropriate namespace declarations within the fragment itself.

Specified by:
addChildElement in interface SOAPElement
Parameters:
element - the SOAPElement to be added as a new child
Returns:
an instance representing the new SOAP element that was actually added to the tree.
Throws:
SOAPException - if there was an error in adding this element as a child

addTextNode

public SOAPElement addTextNode(java.lang.String text)
                        throws SOAPException
Not supported, always throws UnsupportedOperationException

Specified by:
addTextNode in interface SOAPElement
Parameters:
text -
Returns:
Throws:
SOAPException

addAttribute

public SOAPElement addAttribute(Name name,
                                java.lang.String value)
                         throws SOAPException
Not supported, always throws UnsupportedOperationException

Specified by:
addAttribute in interface SOAPElement
Parameters:
name -
value -
Returns:
Throws:
SOAPException

addNamespaceDeclaration

public SOAPElement addNamespaceDeclaration(java.lang.String prefix,
                                           java.lang.String uri)
                                    throws SOAPException
Not supported, always throws UnsupportedOperationException

Specified by:
addNamespaceDeclaration in interface SOAPElement
Parameters:
prefix -
uri -
Returns:
Throws:
SOAPException

getAttributeValue

public java.lang.String getAttributeValue(Name name)
Description copied from interface: SOAPElement
Returns the value of the attribute with the specified name.

Specified by:
getAttributeValue in interface SOAPElement
Parameters:
name - a Name object with the name of the attribute
Returns:
a String giving the value of the specified attribute

getAllAttributes

public java.util.Iterator getAllAttributes()
Description copied from interface: SOAPElement
Returns an iterator over all of the attribute names in this SOAPElement object. The iterator can be used to get the attribute names, which can then be passed to the method getAttributeValue to retrieve the value of each attribute.

Specified by:
getAllAttributes in interface SOAPElement
Returns:
an iterator over the names of the attributes

getNamespaceURI

public java.lang.String getNamespaceURI(java.lang.String prefix)
Not supported, always throws UnsupportedOperationException

Specified by:
getNamespaceURI in interface SOAPElement
Parameters:
prefix -
Returns:

getNamespacePrefixes

public java.util.Iterator getNamespacePrefixes()
Not supported, always throws UnsupportedOperationException

Specified by:
getNamespacePrefixes in interface SOAPElement
Returns:

getElementName

public Name getElementName()
Not supported, always throws UnsupportedOperationException

Specified by:
getElementName in interface SOAPElement
Returns:

removeAttribute

public boolean removeAttribute(Name name)
Not supported, always throws UnsupportedOperationException

Specified by:
removeAttribute in interface SOAPElement
Parameters:
name -
Returns:

removeNamespaceDeclaration

public boolean removeNamespaceDeclaration(java.lang.String prefix)
Not supported, always throws UnsupportedOperationException

Specified by:
removeNamespaceDeclaration in interface SOAPElement
Parameters:
prefix -
Returns:

getChildElements

public java.util.Iterator getChildElements()
Description copied from interface: SOAPElement
Returns an iterator over all the immediate content of this element. This includes Text objects as well as SOAPElement objects.

Specified by:
getChildElements in interface SOAPElement
Returns:
an iterator with the content of this SOAPElement object

getChildElements

public java.util.Iterator getChildElements(Name name)
Description copied from interface: SOAPElement
Returns an iterator over all the child elements with the specified name.

Specified by:
getChildElements in interface SOAPElement
Parameters:
name - a Name object with the name of the child elements to be returned
Returns:
an Iterator object over all the elements in this SOAPElement object with the specified name

setEncodingStyle

public void setEncodingStyle(java.lang.String encodingStyle)
                      throws SOAPException
Description copied from interface: SOAPElement
Sets the encoding style for this SOAPElement object to one specified.

Specified by:
setEncodingStyle in interface SOAPElement
Parameters:
encodingStyle - a String giving the encoding style
Throws:
SOAPException
See Also:
SOAPElement.getEncodingStyle()

getEncodingStyle

public java.lang.String getEncodingStyle()
Description copied from interface: SOAPElement
Returns the encoding style for this SOAPElement object.

Specified by:
getEncodingStyle in interface SOAPElement
Returns:
a String giving the encoding style
See Also:
SOAPElement.setEncodingStyle(java.lang.String)

getValue

public java.lang.String getValue()
Description copied from interface: Node
Returns the the value of the immediate child of this Node object if a child exists and its value is text.

Specified by:
getValue in interface Node
Returns:
a String with the text of the immediate child of this Node object if (1) there is a child and (2) the child is a Text object; null otherwise

setParentElement

public void setParentElement(SOAPElement parent)
                      throws SOAPException
Not supported, always throws UnsupportedOperationException

Specified by:
setParentElement in interface Node
Parameters:
parent -
Throws:
SOAPException
See Also:
Node.getParentElement()

getParentElement

public SOAPElement getParentElement()
Not supported, always throws UnsupportedOperationException

Specified by:
getParentElement in interface Node
Returns:
See Also:
Node.setParentElement(javax.xml.soap.SOAPElement)

detachNode

public void detachNode()
Not supported, always throws UnsupportedOperationException

Specified by:
detachNode in interface Node

recycleNode

public void recycleNode()
Description copied from interface: Node
Notifies the implementation that this Node object is no longer being used by the application and that the implementation is free to reuse this object for nodes that may be created later.

Calling the method recycleNode implies that the method detachNode has been called previously.

Specified by:
recycleNode in interface Node

readExternal

public void readExternal(java.io.ObjectInput in)
                  throws java.io.IOException,
                         java.lang.ClassNotFoundException
* Current implementation deserializes a String created from this instance

Specified by:
readExternal in interface java.io.Externalizable
Parameters:
in -
Throws:
java.io.IOException
java.lang.ClassNotFoundException

writeExternal

public void writeExternal(java.io.ObjectOutput out)
                   throws java.io.IOException
Current implementation serializes a String created from this instance

Specified by:
writeExternal in interface java.io.Externalizable
Parameters:
out -
Throws:
java.io.IOException

getContent

public javax.xml.transform.Source getContent()
Return source

Returns:
instance of org.idoox.xml.TokenizerSource

setContent

public void setContent(javax.xml.transform.Source source)
Set content from specified Source. Note that source must be instance of org.idoox.xml.TokenizerSource

Parameters:
source - instance of org.idoox.xml.TokenizerSource

getInternalSOAPElement

public SOAPElement getInternalSOAPElement()
Specified by:
getInternalSOAPElement in interface org.systinet.wasp.addressing.ReferencePropertiesInternal

setInternalSOAPElement

public void setInternalSOAPElement(SOAPElement element)
Specified by:
setInternalSOAPElement in interface org.systinet.wasp.addressing.ReferencePropertiesInternal