Top Description Fields Constructors Methods
org.hibernate.id.enhanced

public Class OptimizerFactory

extends Object
Class Inheritance
Imports
java.lang.reflect.Constructor, java.util.Properties, org.hibernate.cfg.AvailableSettings, org.hibernate.internal.CoreMessageLogger, org.hibernate.internal.util.ReflectHelper, .StringHelper, org.hibernate.internal.util.config.ConfigurationHelper, org.jboss.logging.Logger

Factory for Optimizer instances.
Author
Steve Ebersole

Field Summary

Modifier and TypeField and Description
private static final Class<T>[]
public static final String
HILO

Deprecated!

public static final String
LEGACY_HILO

Deprecated!

private static final CoreMessageLogger
public static final String
NONE

Deprecated!

public static final String
POOL

Deprecated!

public static final String
POOL_LO

Deprecated!

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
private static Optimizer
buildFallbackOptimizer(Class<T> returnClass, int incrementSize)

public static Optimizer

Returns:

The built optimizer
buildOptimizer
(String
The optimizer type, either a short-hand name or the Optimizer class name.
type
,
Class<T>
The generated value java type
returnClass
,
int
The increment size.
incrementSize
)

Builds an optimizer
public static Optimizer

Returns:

The built optimizer
buildOptimizer
(String
The optimizer type, either a short-hand name or the Optimizer class name.
type
,
Class<T>
The generated value java type
returnClass
,
int
The increment size.
incrementSize
,
long
The user supplied initial-value (-1 indicates the user did not specify).
explicitInitialValue
)

Builds an optimizer

public static String
determineImplicitOptimizerName(int incrementSize, Properties configSettings)

Determine the optimizer to use when there was not one explicitly specified.

public static boolean

Returns:

true indicates the optimizer is a pooled strategy.
isPooledOptimizer
(String
The name of the optimizer
optimizerName
)

Does the given optimizer name represent a pooled strategy?

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

CTOR_SIGback to summary
private static final Class<T>[] CTOR_SIG
HILOback to summary
public static final String HILO

Deprecated!

Annotations
@Deprecated
@SuppressWarnings:UnusedDeclaration
LEGACY_HILOback to summary
public static final String LEGACY_HILO

Deprecated!

Annotations
@Deprecated
@SuppressWarnings:UnusedDeclaration
LOGback to summary
private static final CoreMessageLogger LOG
NONEback to summary
public static final String NONE

Deprecated!

Annotations
@Deprecated
@SuppressWarnings:UnusedDeclaration
POOLback to summary
public static final String POOL

Deprecated!

Annotations
@Deprecated
@SuppressWarnings:UnusedDeclaration
POOL_LOback to summary
public static final String POOL_LO

Deprecated!

Annotations
@Deprecated
@SuppressWarnings:UnusedDeclaration

Constructor Detail

OptimizerFactoryback to summary
private OptimizerFactory()

Method Detail

buildFallbackOptimizerback to summary
private static Optimizer buildFallbackOptimizer(Class<T> returnClass, int incrementSize)
buildOptimizerback to summary
public static Optimizer buildOptimizer(String type, Class<T> returnClass, int incrementSize)

Builds an optimizer

Parameters
type:String

The optimizer type, either a short-hand name or the Optimizer class name.

returnClass:Class<T>

The generated value java type

incrementSize:int

The increment size.

Returns:Optimizer

The built optimizer

Annotations
@Deprecated
buildOptimizerback to summary
public static Optimizer buildOptimizer(String type, Class<T> returnClass, int incrementSize, long explicitInitialValue)

Builds an optimizer

Parameters
type:String

The optimizer type, either a short-hand name or the Optimizer class name.

returnClass:Class<T>

The generated value java type

incrementSize:int

The increment size.

explicitInitialValue:long

The user supplied initial-value (-1 indicates the user did not specify).

Returns:Optimizer

The built optimizer

determineImplicitOptimizerNameback to summary
public static String determineImplicitOptimizerName(int incrementSize, Properties configSettings)

Determine the optimizer to use when there was not one explicitly specified.

isPooledOptimizerback to summary
public static boolean isPooledOptimizer(String optimizerName)

Does the given optimizer name represent a pooled strategy?

Parameters
optimizerName:String

The name of the optimizer

Returns:boolean

true indicates the optimizer is a pooled strategy.