Overview | Package | Class | Use | Tree | Deprecated | Index | Help
|  | BEA Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

WebLogic Server 6.0sp2 API Reference

## weblogic.apache.xalan.xpath.xml
Class PrefixResolverDefault

    java.lang.Object
      |
      +--weblogic.apache.xalan.xpath.xml.PrefixResolverDefault

public class PrefixResolverDefault
extends java.lang.Object
implements PrefixResolver

This class implements a generic PrefixResolver that can be used to perform prefix-to-namespace lookup for the XPath object.

This class is based on an implementation from the Apache XML Project. In future releases the XML parser, XSLT processor, and associated classes will likely be updated to be based on a later version of the Apache implementations. Since Apache does not guarantee backwards compatibility between versions of their software, we cannot guarantee backwards compatibility of any of the classes contained in the weblogic.apache package or sub-packages.

Author:
  Copyright © 2001 BEA Systems, Inc. All Rights Reserved.

Field Summary
`static java.lang.String` | `S_XMLNAMESPACEURI` The URI for the XML namespace.

Constructor Summary
`PrefixResolverDefault(org.w3c.dom.Node xpathExpressionContext)` Construct a PrefixResolverDefault object.

Method Summary
`java.lang.String` | `getBaseIdentifier()` Return the base identifier.
`java.lang.String` | `getNamespaceForPrefix(java.lang.String prefix)` Given a namespace, get the corrisponding prefix.
`java.lang.String` | `getNamespaceForPrefix(java.lang.String prefix, org.w3c.dom.Node namespaceContext)` Given a namespace, get the corrisponding prefix.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### S_XMLNAMESPACEURI

    public static final java.lang.String S_XMLNAMESPACEURI

  The URI for the XML namespace. (Duplicate of that found in weblogic.apache.xalan.xpath.xml.XMLParserLiaisonDefault).

Constructor Detail

### PrefixResolverDefault

    public PrefixResolverDefault(org.w3c.dom.Node xpathExpressionContext)

  Construct a PrefixResolverDefault object.

  Parameters:
    `xpathExpressionContext` - The context from which XPath expression prefixes will be resolved. Warning: This will not work correctly if xpathExpressionContext is an attribute node.
    `xpathExpressionContext` - Node from which to start searching for a xmlns attribute that binds a prefix to a namespace (when the namespace context is not specified in the getNamespaceForPrefix call).

Method Detail

### getNamespaceForPrefix

    public java.lang.String getNamespaceForPrefix(java.lang.String prefix)

  Given a namespace, get the corrisponding prefix. This assumes that the PrevixResolver hold's it's own namespace context, or is a namespace context itself.
  Specified by:
    getNamespaceForPrefix in interface PrefixResolver

  Parameters:
    `prefix` - Prefix to resolve.
  Returns:
    Namespace that prefix resolves to, or null if prefix is not bound.

### getNamespaceForPrefix

    public java.lang.String getNamespaceForPrefix(java.lang.String prefix,
                                                  org.w3c.dom.Node namespaceContext)

  Given a namespace, get the corrisponding prefix. Warning: This will not work correctly if namespaceContext is an attribute node.
  Specified by:
    getNamespaceForPrefix in interface PrefixResolver

  Parameters:
    `prefix` - Prefix to resolve.
    `namespaceContext` - Node from which to start searching for a xmlns attribute that binds a prefix to a namespace.
  Returns:
    Namespace that prefix resolves to, or null if prefix is not bound.

### getBaseIdentifier

    public java.lang.String getBaseIdentifier()

  Return the base identifier.
  Specified by:
    getBaseIdentifier in interface PrefixResolver

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Documentation is available at http://e-docs.bea.com/wls/docs60
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD