Package com.helger.xml.namespace
Class SingleElementNamespaceContext
java.lang.Object
com.helger.xml.namespace.AbstractNamespaceContext
com.helger.xml.namespace.SingleElementNamespaceContext
- All Implemented Interfaces:
IIterableNamespaceContext,NamespaceContext
Represents a namespace context having exactly 1 item.
- Author:
- Philip Helger
-
Constructor Summary
ConstructorsConstructorDescriptionSingleElementNamespaceContext(String sNamespaceURI) Create a namespace context with the default (empty) prefixSingleElementNamespaceContext(String sPrefix, String sNamespaceURI) -
Method Summary
Modifier and TypeMethodDescriptionprotected StringgetCustomNamespaceURI(String sPrefix) protected StringgetCustomPrefix(String sNamespaceURI) getCustomPrefixes(String sNamespaceURI) Get all contained mappings.toString()Methods inherited from class com.helger.xml.namespace.AbstractNamespaceContext
getNamespaceURI, getPrefix, getPrefixes
-
Constructor Details
-
SingleElementNamespaceContext
Create a namespace context with the default (empty) prefix- Parameters:
sNamespaceURI- The namespace URI to use. May neither benullnor empty.
-
SingleElementNamespaceContext
-
-
Method Details
-
getDefaultNamespaceURI
- Specified by:
getDefaultNamespaceURIin classAbstractNamespaceContext
-
getCustomPrefixes
- Specified by:
getCustomPrefixesin classAbstractNamespaceContext
-
getCustomPrefix
- Specified by:
getCustomPrefixin classAbstractNamespaceContext
-
getCustomNamespaceURI
- Specified by:
getCustomNamespaceURIin classAbstractNamespaceContext
-
getPrefixToNamespaceURIMap
@Nonnull @ReturnsMutableCopy public com.helger.commons.collection.impl.ICommonsMap<String,String> getPrefixToNamespaceURIMap()Description copied from interface:IIterableNamespaceContextGet all contained mappings.- Returns:
- The map with all prefixes mapped to the namespace URIs.
-
toString
-