Java in a Nutshell, 5th Edition [Electronic resources]

نسخه متنی -صفحه : 1191/ 1041
نمايش فراداده

NamespaceContextjavax.xml.namespace

Java 5.0

This interface represents a mapping between namespace URIs and the local prefixes that are bound to them. Use getNamepaceURI( ) to obtain the URI that a prefix is bound to. Use getPrefix( ) to do the reverse. More than one prefix can be bound to the same URI, and the getPrefixes( ) method returns an Iterator that you can use to loop through all prefixes that have been associated with a given URI.

public interface

NamespaceContext { // Public Instance Methods String

getNamespaceURI (String

prefix ); String

getPrefix (String

namespaceURI ); java.util.Iterator

getPrefixes (String

namespaceURI ); }

Passed To

javax.xml.xpath.XPath.setNamespaceContext( )

Returned By

javax.xml.xpath.XPath.getNamespaceContext( )