Xerces2 Implementation: Class SchemaNamespaceSupport

Overview | Package | Class | Tree | Serialized | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.xerces.impl.xs
Class SchemaNamespaceSupport

    java.lang.Object
      |
      +--org.apache.xerces.util.NamespaceSupport
            |
            +--org.apache.xerces.impl.xs.SchemaNamespaceSupport

All Implemented Interfaces:
  org.apache.xerces.xni.NamespaceContext

public class SchemaNamespaceSupport
extends NamespaceSupport

This class customizes the behaviour of the util.NamespaceSupport class in order to easily implement some features that we need for efficient schema handling. It will not be generally useful.

# INTERNAL:

  Usage of this class is not supported. It may be altered or removed at any time.

Version:
  $Id: SchemaNamespaceSupport.java 446734 2006-09-15 20:51:23Z mrglavas $
Author:
  Neil Graham, IBM

Inner classes inherited from class org.apache.xerces.util.NamespaceSupport
`NamespaceSupport.Prefixes`

Fields inherited from class org.apache.xerces.util.NamespaceSupport
`fContext, fCurrentContext, fNamespace, fNamespaceSize, fPrefixes`

Fields inherited from interface org.apache.xerces.xni.NamespaceContext
`XML_URI, XMLNS_URI`

Constructor Summary
`SchemaNamespaceSupport(org.w3c.dom.Element schemaRoot, SymbolTable symbolTable)`
`SchemaNamespaceSupport(SchemaNamespaceSupport nSupport)`

Method Summary
`java.lang.String[]` | `getEffectiveLocalContext()` This method returns an array of Strings, as would be stored in a NamespaceSupport object.
`java.lang.String` | `getURI(java.lang.String prefix)` Look up a prefix and get the currently-mapped Namespace URI.
`void` | `makeGlobal()`
`void` | `setEffectiveContext(java.lang.String[] namespaceDecls)` This method takes a set of Strings, as stored in a NamespaceSupport object, and "fools" the object into thinking that this is one unified context.

Methods inherited from class org.apache.xerces.util.NamespaceSupport
`containsPrefix, declarePrefix, getAllPrefixes, getDeclaredPrefixAt, getDeclaredPrefixCount, getPrefix, popContext, pushContext, reset`

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

Constructor Detail

### SchemaNamespaceSupport

    public SchemaNamespaceSupport(org.w3c.dom.Element schemaRoot,
                                  SymbolTable symbolTable)

### SchemaNamespaceSupport

    public SchemaNamespaceSupport(SchemaNamespaceSupport nSupport)

Method Detail

### setEffectiveContext

    public void setEffectiveContext(java.lang.String[] namespaceDecls)

  This method takes a set of Strings, as stored in a NamespaceSupport object, and "fools" the object into thinking that this is one unified context. This is meant to be used in conjunction with things like local elements, whose declarations may be deeply nested but which for all practical purposes may be regarded as being one level below the global element--at least with regard to namespace declarations. It's worth noting that the context from which the strings are being imported had better be using the same SymbolTable.

### getEffectiveLocalContext

    public java.lang.String[] getEffectiveLocalContext()

  This method returns an array of Strings, as would be stored in a NamespaceSupport object. This array contains all declarations except those at the global level.

### makeGlobal

    public void makeGlobal()

### getURI

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

  Description copied from interface: `org.apache.xerces.xni.NamespaceContext`
  Look up a prefix and get the currently-mapped Namespace URI.

  This method looks up the prefix in the current context. If no mapping is found, this methods will continue lookup in the parent context(s). Use the empty string ("") for the default Namespace.

  Overrides:
    `getURI` in class `NamespaceSupport`
  Following copied from class: `org.apache.xerces.util.NamespaceSupport`
  See Also:
    `NamespaceContext.getURI(String)`

Overview | Package | Class | Tree | Serialized | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 1999-2010 The Apache Software Foundation. All Rights Reserved.