QName | javax.xml.namespace |
JAX-RPC 1.0; JWSDP 1.0, J2EE 1.4 | serializable |
public class QName implements java.io.Serializable { // Public Constructors public QName( String localPart ); public QName( String namespaceURI , String localPart ); // Public Class Methods public static QName valueOf( String s ); // Public Instance Methods public String getLocalPart( ); public String getNamespaceURI( ); // Public Methods Overriding Object public final boolean equals( Object obj ); public final int hashCode( ); public String toString( ); }
This class represents an XML-qualified name . The two-argument constructor creates a QName object with a given local part and namespace URI. The one-argument constructor creates a QName object that does not have an explicitly specified namespace. An XML element associated with a QName that does not have an explicit namespace is considered to be in the default namespace that is in force for that element. The URI for the default namespace is determined by an xmlns attribute with no associated prefix, placed either on that element or on one of its ancestors .
The getLocalPart( ) and getNamespaceURI( ) methods return the local part and the namespace URI associated with the QName . In the case of a QName that does not have a namespace URI, the latter method returns an empty string. The toString( ) method creates a string representation of the QName as follows :
If the name does not have a namespace URI, then the value returned by toString( ) is just the local part of the name.
Otherwise, the value returned is {URI}localPart .
The static valueOf ( ) method accepts a string representation of a qualified name in the form returned by toString( ) and converts it to a QName object. For example, the result of the call QName.valueOf("{URI}localPart") is the same as using the constructor QName("URI ", " localPart") , whereas QName.valueOf("localPart") produces the same result as QName("localPart") . If the argument cannot be decoded as a QName , then a java.lang.IllegalArgumentException is thrown.
Too many methods to list.
QName.valueOf( ) , javax.xml.rpc.Call.{getOperationName( ) , getParameterTypeByName( ) , getPortTypeName( ) , getReturnType( )} , javax.xml.rpc.Service.getServiceName( ) , javax.xml.rpc.handler.GenericHandler.getHeaders( ) , javax.xml.rpc.handler.Handler.getHeaders( ) , javax.xml.rpc.handler.HandlerInfo.getHeaders( ) , javax.xml.rpc.soap.SOAPFaultException.getFaultCode( )
javax.xml.rpc.encoding.XMLType.{SOAP_ARRAY , SOAP_BASE64 , SOAP_BOOLEAN , SOAP_BYTE , SOAP_DOUBLE , SOAP_FLOAT , SOAP_INT , SOAP_LONG , SOAP_SHORT , SOAP_STRING , XSD_BASE64 , XSD_BOOLEAN , XSD_BYTE , XSD_DATETIME , XSD_DECIMAL , XSD_DOUBLE , XSD_FLOAT , XSD_HEXBINARY , XSD_INT , XSD_INTEGER , XSD_LONG , XSD_QNAME , XSD_SHORT , XSD_STRING} , javax.xml.rpc.holders.QNameHolder.value