Top Description Methods
org.hibernate.boot.spi

public Interface ClassLoaderAccess

Known Direct Implementers
org.hibernate.boot.internal.ClassLoaderAccessImpl, org.hibernate.boot.model.internal.ClassLoaderAccessLazyImpl
Imports
java.net.URL

During the process of building the metamodel, access to the ClassLoader is strongly discouraged. However, sometimes it is needed. This contract helps mitigate access to the ClassLoader in these cases.
Author
Steve Ebersole
Since
5.0

Method Summary

Modifier and TypeMethod and Description
public <T> Class<T>

Returns:

The Class object with the given name
classForName
(String
The name of the class
name
)

Obtain a Class reference by name

public URL

Returns:

The located resource; may return null to indicate the resource was not found
locateResource
(String
The name of the resource to resolve
resourceName
)

Locate a resource by name

Method Detail

classForNameback to summary
public <T> Class<T> classForName(String name)

Obtain a Class reference by name

Parameters
name:String

The name of the class

Returns:Class<T>

The Class object with the given name

locateResourceback to summary
public URL locateResource(String resourceName)

Locate a resource by name

Parameters
resourceName:String

The name of the resource to resolve

Returns:URL

The located resource; may return null to indicate the resource was not found