HiLoOptimizer, maintaining compatibility with the values generated by the
legacy Hibernate hilo based generators.
| Modifier and Type | Class and Description |
|---|---|
| private static class |
| Modifier and Type | Field and Description |
|---|---|
| private final long | |
| private static final Logger | |
| private LegacyHiLoAlgorithmOptimizer. | |
| private Map |
| Access | Constructor and Description |
|---|---|
| public | LegacyHiLoAlgorithmOptimizer(Class<T>
The Java type of the values to be generated returnClass, int The increment size. incrementSize)Constructs a LegacyHiLoAlgorithmOptimizer |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | applyIncrementSizeToSourceValues()
Implements org. |
| private LegacyHiLoAlgorithmOptimizer. | |
| public synchronized Serializable | generate(AccessCallback
Callback to access the underlying value source. callback)Implements org. |
| public synchronized IntegralDataTypeHolder | getLastSourceValue()
Implements org. |
| public synchronized IntegralDataTypeHolder | |
| private LegacyHiLoAlgorithmOptimizer. | |
| private LegacyHiLoAlgorithmOptimizer. |
| initialMaxLo | back to summary |
|---|---|
| private final long initialMaxLo | |
| log | back to summary |
|---|---|
| private static final Logger log | |
| noTenantState | back to summary |
|---|---|
| private LegacyHiLoAlgorithmOptimizer. | |
| tenantSpecificState | back to summary |
|---|---|
| private Map<String, LegacyHiLoAlgorithmOptimizer. | |
| LegacyHiLoAlgorithmOptimizer | back to summary |
|---|---|
| public LegacyHiLoAlgorithmOptimizer(Class<T> returnClass, int incrementSize) Constructs a LegacyHiLoAlgorithmOptimizer
| |
| applyIncrementSizeToSourceValues | back to summary |
|---|---|
| public boolean applyIncrementSizeToSourceValues() Implements org. Doc from org. Are increments to be applied to the values stored in the underlying value source?
| |
| createGenerationState | back to summary |
|---|---|
| private LegacyHiLoAlgorithmOptimizer. | |
| generate | back to summary |
|---|---|
| public synchronized Serializable generate(AccessCallback callback) Implements org. Doc from org. Generate an identifier value accounting for this specific optimization. All known implementors are synchronized. Consider carefully if a new implementation could drop this requirement.
| |
| getLastSourceValue | back to summary |
|---|---|
| public synchronized IntegralDataTypeHolder getLastSourceValue() Implements org. Doc from org. A common means to access the last value obtained from the underlying source. This is intended for testing purposes, since accessing the underlying database source directly is much more difficult.
| |
| getLastValue | back to summary |
|---|---|
| public synchronized IntegralDataTypeHolder getLastValue() Getter for property 'lastValue'. Exposure intended for testing purposes.
| |
| locateGenerationState | back to summary |
|---|---|
| private LegacyHiLoAlgorithmOptimizer. | |
| noTenantGenerationState | back to summary |
|---|---|
| private LegacyHiLoAlgorithmOptimizer. | |
| Modifier and Type | Field and Description |
|---|---|
| private IntegralDataTypeHolder | |
| private IntegralDataTypeHolder | |
| private long | |
| private long | |
| private IntegralDataTypeHolder |
| Access | Constructor and Description |
|---|---|
| private |
| hi | back to summary |
|---|---|
| private IntegralDataTypeHolder hi | |
| lastSourceValue | back to summary |
|---|---|
| private IntegralDataTypeHolder lastSourceValue | |
| lo | back to summary |
|---|---|
| private long lo | |
| maxLo | back to summary |
|---|---|
| private long maxLo | |
| value | back to summary |
|---|---|
| private IntegralDataTypeHolder value | |
| GenerationState | back to summary |
|---|---|
| private GenerationState() | |