Module org.eclipse.persistence.core
Class NamespacePrefixMapperWrapper
- java.lang.Object
-
- org.eclipse.persistence.internal.oxm.NamespacePrefixMapper
-
- org.eclipse.persistence.oxm.NamespacePrefixMapper
-
- org.eclipse.persistence.internal.oxm.record.namespaces.NamespacePrefixMapperWrapper
-
public class NamespacePrefixMapperWrapper extends NamespacePrefixMapper
INTERNAL:Purpose:This class provides an implementation of NamespacePrefixMapper that wraps an implementation of the equivalent NamespacePrefixMapper from the JAXB ReferenceImplementation This allows for backwards compatibility with the JAXB RI.
-
-
Constructor Summary
Constructors Constructor Description NamespacePrefixMapperWrapper(Object prefixMapper)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String[]getContextualNamespaceDecls()Returns a string array of prefixes and namespace uris that are already available in this context.String[]getPreDeclaredNamespaceUris()Returns a list of namespace uris that should be declared at the root of the xml document being marshalled.String[]getPreDeclaredNamespaceUris2()Returns a string array of prefixes and namespace uris to be declared at the root of the document.StringgetPreferredPrefix(String namespaceUri, String suggestion, boolean requirePrefix)ObjectgetPrefixMapper()-
Methods inherited from class org.eclipse.persistence.oxm.NamespacePrefixMapper
supportsMediaType
-
-
-
-
Constructor Detail
-
NamespacePrefixMapperWrapper
public NamespacePrefixMapperWrapper(Object prefixMapper)
-
-
Method Detail
-
getPreferredPrefix
public String getPreferredPrefix(String namespaceUri, String suggestion, boolean requirePrefix)
- Specified by:
getPreferredPrefixin classNamespacePrefixMapper
-
getContextualNamespaceDecls
public String[] getContextualNamespaceDecls()
Description copied from class:NamespacePrefixMapperReturns a string array of prefixes and namespace uris that are already available in this context. Only required when marshalling to an output stream or a writer, since it's not possible to determine which namespaces are already in scope.- Overrides:
getContextualNamespaceDeclsin classNamespacePrefixMapper
-
getPreDeclaredNamespaceUris
public String[] getPreDeclaredNamespaceUris()
Description copied from class:NamespacePrefixMapperReturns a list of namespace uris that should be declared at the root of the xml document being marshalled.- Overrides:
getPreDeclaredNamespaceUrisin classNamespacePrefixMapper
-
getPreDeclaredNamespaceUris2
public String[] getPreDeclaredNamespaceUris2()
Description copied from class:NamespacePrefixMapperReturns a string array of prefixes and namespace uris to be declared at the root of the document. This eliminates the need of implementing both getPredeclaredNamespaceUris and getPreferredPrefix since the prefix and uri can be associated here.- Overrides:
getPreDeclaredNamespaceUris2in classNamespacePrefixMapper
-
getPrefixMapper
public Object getPrefixMapper()
-
-