public class

SimpleNamespaceContext

extends Object
implements NamespaceContext
java.lang.Object
   ↳ org.springframework.util.xml.SimpleNamespaceContext

Class Overview

Simple javax.xml.namespace.NamespaceContext implementation. Follows the standard NamespaceContext contract, and is loadable via a java.util.Map or java.util.Properties object

Summary

Public Constructors
SimpleNamespaceContext()
Public Methods
void bindDefaultNamespaceUri(String namespaceUri)
Binds the given namespace as default namespace.
void bindNamespaceUri(String prefix, String namespaceUri)
Binds the given prefix to the given namespace.
void clear()
Removes all declared prefixes.
Iterator<String> getBoundPrefixes()
Returns all declared prefixes.
String getNamespaceURI(String prefix)
String getPrefix(String namespaceUri)
Iterator getPrefixes(String namespaceUri)
void removeBinding(String prefix)
Removes the given prefix from this context.
void setBindings(Map<StringString> bindings)
Sets the bindings for this namespace context.
[Expand]
Inherited Methods
From class java.lang.Object
From interface javax.xml.namespace.NamespaceContext

Public Constructors

public SimpleNamespaceContext ()

Also: SpringCore

Public Methods

public void bindDefaultNamespaceUri (String namespaceUri)

Also: SpringCore

Binds the given namespace as default namespace.

Parameters
namespaceUri the namespace uri

public void bindNamespaceUri (String prefix, String namespaceUri)

Also: SpringCore

Binds the given prefix to the given namespace.

Parameters
prefix the namespace prefix
namespaceUri the namespace uri

public void clear ()

Also: SpringCore

Removes all declared prefixes.

public Iterator<String> getBoundPrefixes ()

Also: SpringCore

Returns all declared prefixes.

Returns
  • the declared prefixes

public String getNamespaceURI (String prefix)

Also: SpringCore

public String getPrefix (String namespaceUri)

Also: SpringCore

public Iterator getPrefixes (String namespaceUri)

Also: SpringCore

public void removeBinding (String prefix)

Also: SpringCore

Removes the given prefix from this context.

Parameters
prefix the prefix to be removed

public void setBindings (Map<StringString> bindings)

Also: SpringCore

Sets the bindings for this namespace context. The supplied map must consist of string key value pairs.

Parameters
bindings the bindings