Top Inners Fields Constructors Methods
org.hibernate.boot.archive.scan.spi

public abstract Class AbstractScannerImpl

extends Object
implements Scanner
Class Inheritance
All Implemented Interfaces
org.hibernate.boot.archive.scan.spi.Scanner
Known Direct Subclasses
org.hibernate.boot.archive.scan.internal.StandardScanner
Imports
java.net.URL, java.util.HashMap, .Map, org.hibernate.boot.archive.scan.internal.NoopEntryHandler, .ScanResultCollector, org.hibernate.boot.archive.spi.ArchiveContext, .ArchiveDescriptor, .ArchiveDescriptorFactory, .ArchiveEntry, .ArchiveEntryHandler, .JarFileEntryUrlAdjuster

Author
Steve Ebersole

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class
protected static class

Field Summary

Modifier and TypeField and Description
private final Map<URL, AbstractScannerImpl.ArchiveDescriptorInfo>
private final ArchiveDescriptorFactory

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
private ArchiveDescriptor
buildArchiveDescriptor(URL url, ScanEnvironment environment, boolean isRootUrl)

protected URL

Returns:

The resolved non-root URL
resolveNonRootUrl
(URL url)

Handle <jar-file/> references from a persistence.xml file.

public ScanResult
scan(ScanEnvironment
The scan environment.
environment
,
ScanOptions
The options to control the scanning.
options
,
ScanParameters
The parameters for scanning
parameters
)

Implements org.hibernate.boot.archive.scan.spi.Scanner.scan.

Perform the scanning against the described environment using the defined options, and return the scan results.
protected void
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

archiveDescriptorCacheback to summary
private final Map<URL, AbstractScannerImpl.ArchiveDescriptorInfo> archiveDescriptorCache
archiveDescriptorFactoryback to summary
private final ArchiveDescriptorFactory archiveDescriptorFactory

Constructor Detail

AbstractScannerImplback to summary
protected AbstractScannerImpl(ArchiveDescriptorFactory archiveDescriptorFactory)

Method Detail

buildArchiveDescriptorback to summary
private ArchiveDescriptor buildArchiveDescriptor(URL url, ScanEnvironment environment, boolean isRootUrl)
resolveNonRootUrlback to summary
protected URL resolveNonRootUrl(URL url)

Handle <jar-file/> references from a persistence.xml file. JPA allows for to be specific

Returns:URL

The resolved non-root URL

scanback to summary
public ScanResult scan(ScanEnvironment environment, ScanOptions options, ScanParameters parameters)

Implements org.hibernate.boot.archive.scan.spi.Scanner.scan.

Doc from org.hibernate.boot.archive.scan.spi.Scanner.scan.

Perform the scanning against the described environment using the defined options, and return the scan results.

Parameters
environment:ScanEnvironment

The scan environment.

options:ScanOptions

The options to control the scanning.

parameters:ScanParameters

The parameters for scanning

Annotations
@Override
validateReuseback to summary
protected void validateReuse(AbstractScannerImpl.ArchiveDescriptorInfo descriptor, boolean root)
Annotations
@SuppressWarnings:UnusedParameters
org.hibernate.boot.archive.scan.spi back to summary

public Class AbstractScannerImpl.ArchiveContextImpl

extends Object
implements ArchiveContext
Class Inheritance
  • java.lang.Object
  • org.hibernate.boot.archive.scan.spi.AbstractScannerImpl.ArchiveContextImpl
All Implemented Interfaces
org.hibernate.boot.archive.spi.ArchiveContext

Field Summary

Modifier and TypeField and Description
private final ClassFileArchiveEntryHandler
private final ArchiveEntryHandler
private final boolean
private final PackageInfoArchiveEntryHandler

Constructor Summary

AccessConstructor and Description
public
ArchiveContextImpl(boolean isRootUrl, ScanResultCollector scanResultCollector)

Method Summary

Modifier and TypeMethod and Description
public boolean
isRootUrl()

Implements org.hibernate.boot.archive.spi.ArchiveContext.isRootUrl.

Is the archive described (and being visited) the root url for the persistence-unit?
public ArchiveEntryHandler
obtainArchiveEntryHandler(ArchiveEntry
The archive entry
entry
)

Implements org.hibernate.boot.archive.spi.ArchiveContext.obtainArchiveEntryHandler.

Get the handler for the given entry, which generally is indicated by the entry type (a .class file, a mapping file, etc).
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

classEntryHandlerback to summary
private final ClassFileArchiveEntryHandler classEntryHandler
fileEntryHandlerback to summary
private final ArchiveEntryHandler fileEntryHandler
isRootUrlback to summary
private final boolean isRootUrl
packageEntryHandlerback to summary
private final PackageInfoArchiveEntryHandler packageEntryHandler

Constructor Detail

ArchiveContextImplback to summary
public ArchiveContextImpl(boolean isRootUrl, ScanResultCollector scanResultCollector)

Method Detail

isRootUrlback to summary
public boolean isRootUrl()

Implements org.hibernate.boot.archive.spi.ArchiveContext.isRootUrl.

Doc from org.hibernate.boot.archive.spi.ArchiveContext.isRootUrl.

Is the archive described (and being visited) the root url for the persistence-unit?

Returns:boolean

true if it is the root url

Annotations
@Override
obtainArchiveEntryHandlerback to summary
public ArchiveEntryHandler obtainArchiveEntryHandler(ArchiveEntry entry)

Implements org.hibernate.boot.archive.spi.ArchiveContext.obtainArchiveEntryHandler.

Doc from org.hibernate.boot.archive.spi.ArchiveContext.obtainArchiveEntryHandler.

Get the handler for the given entry, which generally is indicated by the entry type (a .class file, a mapping file, etc).

Parameters
entry:ArchiveEntry

The archive entry

Returns:ArchiveEntryHandler

The appropriate handler for the entry

Annotations
@Override
org.hibernate.boot.archive.scan.spi back to summary

protected Class AbstractScannerImpl.ArchiveDescriptorInfo

extends Object
Class Inheritance
  • java.lang.Object
  • org.hibernate.boot.archive.scan.spi.AbstractScannerImpl.ArchiveDescriptorInfo

Field Summary

Modifier and TypeField and Description
public final ArchiveDescriptor
public final boolean

Constructor Summary

AccessConstructor and Description
public
ArchiveDescriptorInfo(ArchiveDescriptor archiveDescriptor, boolean isRoot)

Method Summary

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

archiveDescriptorback to summary
public final ArchiveDescriptor archiveDescriptor
isRootback to summary
public final boolean isRoot

Constructor Detail

ArchiveDescriptorInfoback to summary
public ArchiveDescriptorInfo(ArchiveDescriptor archiveDescriptor, boolean isRoot)