Class 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 Detail

      • NamespacePrefixMapperWrapper

        public NamespacePrefixMapperWrapper​(java.lang.Object prefixMapper)
    • Method Detail

      • getPreferredPrefix

        public java.lang.String getPreferredPrefix​(java.lang.String namespaceUri,
                                                   java.lang.String suggestion,
                                                   boolean requirePrefix)
        Specified by:
        getPreferredPrefix in class NamespacePrefixMapper
      • getContextualNamespaceDecls

        public java.lang.String[] getContextualNamespaceDecls()
        Description copied from class: NamespacePrefixMapper
        Returns 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:
        getContextualNamespaceDecls in class NamespacePrefixMapper
        Returns:
      • getPreDeclaredNamespaceUris2

        public java.lang.String[] getPreDeclaredNamespaceUris2()
        Description copied from class: NamespacePrefixMapper
        Returns 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:
        getPreDeclaredNamespaceUris2 in class NamespacePrefixMapper
        Returns:
      • getPrefixMapper

        public java.lang.Object getPrefixMapper()