Top Description Fields Constructors Methods
org.hibernate.boot.registry.selector.internal

public Class StrategySelectorBuilder

extends Object
Class Inheritance
Imports
java.util.ArrayList, .List, org.hibernate.boot.model.naming.ImplicitNamingStrategy, .ImplicitNamingStrategyComponentPathImpl, .ImplicitNamingStrategyJpaCompliantImpl, .ImplicitNamingStrategyLegacyHbmImpl, .ImplicitNamingStrategyLegacyJpaImpl, org.hibernate.boot.registry.classloading.spi.ClassLoaderService, org.hibernate.boot.registry.selector.SimpleStrategyRegistrationImpl, .StrategyRegistration, .StrategyRegistrationProvider, org.hibernate.boot.registry.selector.spi.StrategySelectionException, .StrategySelector, org.hibernate.cache.internal.DefaultCacheKeysFactory, .SimpleCacheKeysFactory, org.hibernate.cache.spi.CacheKeysFactory, org.hibernate.dialect.Dialect, org.hibernate.engine.transaction.jta.platform.spi.JtaPlatform, org.hibernate.hql.spi.id.MultiTableBulkIdStrategy, org.hibernate.hql.spi.id.global.GlobalTemporaryTableBulkIdStrategy, org.hibernate.hql.spi.id.local.LocalTemporaryTableBulkIdStrategy, org.hibernate.hql.spi.id.persistent.PersistentTableBulkIdStrategy, org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorBuilderImpl, org.hibernate.resource.transaction.backend.jta.internal.JtaTransactionCoordinatorBuilderImpl, org.hibernate.resource.transaction.spi.TransactionCoordinatorBuilder, org.jboss.logging.Logger

Builder for StrategySelector instances.
Author
Steve Ebersole

Field Summary

Modifier and TypeField and Description
private final List<StrategyRegistration<T>>
private static final Logger

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
private void
public <
The type of the strategy. Used to make sure that the strategy and implementation are type compatible.
T
>
void
addExplicitStrategyRegistration(Class<T>
The strategy
strategy
,
Class<? extends T>
The strategy implementation
implementation
,
String
The registered name
name
)

Adds an explicit (as opposed to discovered) strategy registration.

public <
The type of the strategy. Used to make sure that the strategy and implementation are type compatible.
T
>
void
addExplicitStrategyRegistration(StrategyRegistration<T>
The strategy implementation registration.
strategyRegistration
)

Adds an explicit (as opposed to discovered) strategy registration.

private void
private void
private void
private <T> void
applyFromStrategyRegistration(StrategySelectorImpl strategySelector, StrategyRegistration<T> strategyRegistration)

public StrategySelector

Returns:

The selector.
buildSelector
(ClassLoaderService
The class loading service used to (attempt to) resolve any un-registered strategy implementations.
classLoaderService
)

Builds the selector.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

explicitStrategyRegistrationsback to summary
private final List<StrategyRegistration<T>> explicitStrategyRegistrations
logback to summary
private static final Logger log

Constructor Detail

StrategySelectorBuilderback to summary
public StrategySelectorBuilder()

Method Detail

addCacheKeysFactoriesback to summary
private void addCacheKeysFactories(StrategySelectorImpl strategySelector)
addExplicitStrategyRegistrationback to summary
public <T> void addExplicitStrategyRegistration(Class<T> strategy, Class<? extends T> implementation, String name)

Adds an explicit (as opposed to discovered) strategy registration.

Parameters
<T>
The type of the strategy. Used to make sure that the strategy and implementation are type compatible.
strategy:Class<T>

The strategy

implementation:Class<? extends T>

The strategy implementation

name:String

The registered name

Annotations
@SuppressWarnings:unchecked
addExplicitStrategyRegistrationback to summary
public <T> void addExplicitStrategyRegistration(StrategyRegistration<T> strategyRegistration)

Adds an explicit (as opposed to discovered) strategy registration.

Parameters
<T>
The type of the strategy. Used to make sure that the strategy and implementation are type compatible.
strategyRegistration:StrategyRegistration<T>

The strategy implementation registration.

addImplicitNamingStrategiesback to summary
private void addImplicitNamingStrategies(StrategySelectorImpl strategySelector)
addMultiTableBulkIdStrategiesback to summary
private void addMultiTableBulkIdStrategies(StrategySelectorImpl strategySelector)
addTransactionCoordinatorBuildersback to summary
private void addTransactionCoordinatorBuilders(StrategySelectorImpl strategySelector)
applyFromStrategyRegistrationback to summary
private <T> void applyFromStrategyRegistration(StrategySelectorImpl strategySelector, StrategyRegistration<T> strategyRegistration)
Annotations
@SuppressWarnings:unchecked
buildSelectorback to summary
public StrategySelector buildSelector(ClassLoaderService classLoaderService)

Builds the selector.

Parameters
classLoaderService:ClassLoaderService

The class loading service used to (attempt to) resolve any un-registered strategy implementations.

Returns:StrategySelector

The selector.