Module org.eclipse.persistence.core
Interface Sequencing
- All Known Subinterfaces:
SequencingServer
public interface Sequencing
Purpose: Define interface to use sequencing.
Description: This interface accessed through Session.getSequencing() method. Used by EclipseLink internals to obtain sequencing values.
Responsibilities:
- Provides sequencing objects and supporting APIs.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final int -
Method Summary
Modifier and TypeMethodDescriptiongetNextValue(Class<?> cls) INTERNAL: Return the newly-generated sequencing value.intINTERNAL: Indicates when sequencing value should be acquired for all classes.
-
Field Details
-
BEFORE_INSERT
static final int BEFORE_INSERT- See Also:
-
UNDEFINED
static final int UNDEFINED- See Also:
-
AFTER_INSERT
static final int AFTER_INSERT- See Also:
-
-
Method Details
-
whenShouldAcquireValueForAll
int whenShouldAcquireValueForAll()INTERNAL: Indicates when sequencing value should be acquired for all classes. There are just three possible return values: BEFORE_INSERT, UNDEFINED, AFTER_INSERT. Used as a shortcut to avoid individual checks for each class: shouldAcquireValueAfterInsert(Class cls). Currently UNDEFINED only happens in a case of a SessionBroker: session1 - BEFORE_INSERT, session2 - AFTER_INSERT -
getNextValue
INTERNAL: Return the newly-generated sequencing value.- Parameters:
cls- Class for which the sequencing value is generated.
-