Top Inners Fields Constructors Methods
org.hibernate.boot.jaxb.internal.stax

public Class LocalXmlResourceResolver

extends Object
implements XMLResolver
Class Inheritance
All Implemented Interfaces
javax.xml.stream.XMLResolver
Imports
java.io.IOException, .InputStream, java.net.URL, javax.xml.stream.XMLStreamException, org.hibernate.boot.registry.classloading.spi.ClassLoaderService, org.hibernate.internal.log.DeprecationLogger, org.jboss.logging.Logger

Author
Steve Ebersole

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class
public static class

Field Summary

Modifier and TypeField and Description
public static final LocalXmlResourceResolver.DtdMapping
public static final LocalXmlResourceResolver.DtdMapping
public static final LocalXmlResourceResolver.DtdMapping
public static final LocalXmlResourceResolver.NamespaceSchemaMapping
private final ClassLoaderService
public static final String
public static final LocalXmlResourceResolver.DtdMapping
public static final LocalXmlResourceResolver.NamespaceSchemaMapping
public static final LocalXmlResourceResolver.NamespaceSchemaMapping
public static final LocalXmlResourceResolver.NamespaceSchemaMapping
INITIAL_JPA_XSD_MAPPING

Maps the namespace for the orm.xml xsd for jpa 1.0 and 2.0

public static final LocalXmlResourceResolver.NamespaceSchemaMapping
JPA_XSD_MAPPING

Maps the namespace for the orm.xml xsd for jpa 2.1+

public static final LocalXmlResourceResolver.DtdMapping
public static final LocalXmlResourceResolver.DtdMapping
private static final Logger
public static final LocalXmlResourceResolver.NamespaceSchemaMapping
PERSISTENCE_ORM_XSD_MAPPING

Maps the namespace for the orm.xml xsd for Jakarta Persistence 2.2

public static final LocalXmlResourceResolver.NamespaceSchemaMapping
PERSISTENCE_ORM_XSD_MAPPING2

Maps the namespace for the orm.xml xsd for Jakarta Persistence 3.0

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
private InputStream
public Object
resolveEntity(String
The public identifier of the external entity being referenced, or null if none was supplied.
publicID
,
String
The system identifier of the external entity being referenced.
systemID
,
String
Absolute base URI associated with systemId.
baseURI
,
String
The namespace of the entity to resolve.
namespace
)

Implements javax.xml.stream.XMLResolver.resolveEntity.

Retrieves a resource.
private InputStream
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

ALTERNATE_CFG_DTDback to summary
public static final LocalXmlResourceResolver.DtdMapping ALTERNATE_CFG_DTD
ALTERNATE_MAPPING_DTDback to summary
public static final LocalXmlResourceResolver.DtdMapping ALTERNATE_MAPPING_DTD
CFG_DTD_MAPPINGback to summary
public static final LocalXmlResourceResolver.DtdMapping CFG_DTD_MAPPING
CFG_XSD_MAPPINGback to summary
public static final LocalXmlResourceResolver.NamespaceSchemaMapping CFG_XSD_MAPPING
classLoaderServiceback to summary
private final ClassLoaderService classLoaderService
CLASSPATH_EXTENSION_URL_BASEback to summary
public static final String CLASSPATH_EXTENSION_URL_BASE
HBM_DTD_MAPPINGback to summary
public static final LocalXmlResourceResolver.DtdMapping HBM_DTD_MAPPING
HBM_XSD_MAPPINGback to summary
public static final LocalXmlResourceResolver.NamespaceSchemaMapping HBM_XSD_MAPPING
HBM_XSD_MAPPING2back to summary
public static final LocalXmlResourceResolver.NamespaceSchemaMapping HBM_XSD_MAPPING2
INITIAL_JPA_XSD_MAPPINGback to summary
public static final LocalXmlResourceResolver.NamespaceSchemaMapping INITIAL_JPA_XSD_MAPPING

Maps the namespace for the orm.xml xsd for jpa 1.0 and 2.0

JPA_XSD_MAPPINGback to summary
public static final LocalXmlResourceResolver.NamespaceSchemaMapping JPA_XSD_MAPPING

Maps the namespace for the orm.xml xsd for jpa 2.1+

LEGACY_CFG_DTD_MAPPINGback to summary
public static final LocalXmlResourceResolver.DtdMapping LEGACY_CFG_DTD_MAPPING
LEGACY_HBM_DTD_MAPPINGback to summary
public static final LocalXmlResourceResolver.DtdMapping LEGACY_HBM_DTD_MAPPING
logback to summary
private static final Logger log
PERSISTENCE_ORM_XSD_MAPPINGback to summary
public static final LocalXmlResourceResolver.NamespaceSchemaMapping PERSISTENCE_ORM_XSD_MAPPING

Maps the namespace for the orm.xml xsd for Jakarta Persistence 2.2

PERSISTENCE_ORM_XSD_MAPPING2back to summary
public static final LocalXmlResourceResolver.NamespaceSchemaMapping PERSISTENCE_ORM_XSD_MAPPING2

Maps the namespace for the orm.xml xsd for Jakarta Persistence 3.0

Constructor Detail

LocalXmlResourceResolverback to summary
public LocalXmlResourceResolver(ClassLoaderService classLoaderService)

Method Detail

openUrlStreamback to summary
private InputStream openUrlStream(URL url)
resolveEntityback to summary
public Object resolveEntity(String publicID, String systemID, String baseURI, String namespace) throws XMLStreamException

Implements javax.xml.stream.XMLResolver.resolveEntity.

Doc from javax.xml.stream.XMLResolver.resolveEntity.

Retrieves a resource. This resource can be of the following three return types: (1) java.io.InputStream (2) javax.xml.stream.XMLStreamReader (3) java.xml.stream.XMLEventReader. If this method returns null the processor will attempt to resolve the entity using its default mechanism.

Parameters
publicID:String

The public identifier of the external entity being referenced, or null if none was supplied.

systemID:String

The system identifier of the external entity being referenced.

baseURI:String

Absolute base URI associated with systemId.

namespace:String

The namespace of the entity to resolve.

Returns:Object

The resource requested or null.

Annotations
@Override
Exceptions
XMLStreamException:
if there was a failure attempting to resolve the resource.
resolveInLocalNamespaceback to summary
private InputStream resolveInLocalNamespace(String path)
org.hibernate.boot.jaxb.internal.stax back to summary

public Class LocalXmlResourceResolver.DtdMapping

extends Object
Class Inheritance
  • java.lang.Object
  • org.hibernate.boot.jaxb.internal.stax.LocalXmlResourceResolver.DtdMapping

Field Summary

Modifier and TypeField and Description
private final String
private final String
private final URL

Constructor Summary

AccessConstructor and Description
public
DtdMapping(String identifierBase, String resourceName)

Method Summary

Modifier and TypeMethod and Description
public String
public URL
public boolean
matches(String publicId, String systemId)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

httpBaseback to summary
private final String httpBase
httpsBaseback to summary
private final String httpsBase
localSchemaUrlback to summary
private final URL localSchemaUrl

Constructor Detail

DtdMappingback to summary
public DtdMapping(String identifierBase, String resourceName)

Method Detail

getIdentifierBaseback to summary
public String getIdentifierBase()
getMappedLocalUrlback to summary
public URL getMappedLocalUrl()
matchesback to summary
public boolean matches(String publicId, String systemId)
org.hibernate.boot.jaxb.internal.stax back to summary

public Class LocalXmlResourceResolver.NamespaceSchemaMapping

extends Object
Class Inheritance
  • java.lang.Object
  • org.hibernate.boot.jaxb.internal.stax.LocalXmlResourceResolver.NamespaceSchemaMapping

Field Summary

Modifier and TypeField and Description
private final URL
private final String

Constructor Summary

AccessConstructor and Description
public
NamespaceSchemaMapping(String namespace, String resourceName)

Method Summary

Modifier and TypeMethod and Description
public URL
public boolean
matches(String namespace)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

localSchemaUrlback to summary
private final URL localSchemaUrl
namespaceback to summary
private final String namespace

Constructor Detail

NamespaceSchemaMappingback to summary
public NamespaceSchemaMapping(String namespace, String resourceName)

Method Detail

getMappedLocalUrlback to summary
public URL getMappedLocalUrl()
matchesback to summary
public boolean matches(String namespace)