Record Class QueuedCollectionOperation
java.lang.Object
java.lang.Record
org.hibernate.collection.spi.QueuedCollectionOperation
- Record Components:
kind- The command kindaddedValue- The value added or assigned, if applicableorphan- The known previous or removed value, if applicableposition- The map key or absolute list position, if knownorder- The command's zero-based position in the live queue
@Incubating(since="8.0",
group="collection-delta")
public record QueuedCollectionOperation(QueuedCollectionOperation.Kind kind, @Nullable Object addedValue, @Nullable Object orphan, @Nullable Object position, int order)
extends Record
Immutable view of one command in an uninitialized collection's operation queue.
This is producer input, not an independently executable collection mutation.
Command order is significant, and a CLEAR command is an ordering barrier.
- Since:
- 8.0
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionQueuedCollectionOperation(QueuedCollectionOperation.Kind kind, Object addedValue, Object orphan, Object position, int order) Creates an instance of aQueuedCollectionOperationrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theaddedValuerecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.kind()Returns the value of thekindrecord component.intorder()Returns the value of theorderrecord component.orphan()Returns the value of theorphanrecord component.position()Returns the value of thepositionrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
QueuedCollectionOperation
public QueuedCollectionOperation(QueuedCollectionOperation.Kind kind, @Nullable Object addedValue, @Nullable Object orphan, @Nullable Object position, int order) Creates an instance of aQueuedCollectionOperationrecord class.- Parameters:
kind- the value for thekindrecord componentaddedValue- the value for theaddedValuerecord componentorphan- the value for theorphanrecord componentposition- the value for thepositionrecord componentorder- the value for theorderrecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
kind
-
addedValue
Returns the value of theaddedValuerecord component.- Returns:
- the value of the
addedValuerecord component
-
orphan
-
position
-
order
-