Record Class OConsensusSuccess
java.lang.Object
java.lang.Record
com.orientechnologies.orient.distributed.context.coordination.OConsensusSuccess
public record OConsensusSuccess(ODistributedMessage success, OTransactionIdPromise failure, boolean missing, boolean applied)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionOConsensusSuccess(boolean applied) OConsensusSuccess(OTransactionIdPromise failure) OConsensusSuccess(ODistributedMessage success) OConsensusSuccess(ODistributedMessage success, boolean missing) OConsensusSuccess(ODistributedMessage success, OTransactionIdPromise failure, boolean missing, boolean applied) Creates an instance of aOConsensusSuccessrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanapplied()Returns the value of theappliedrecord component.final booleanIndicates whether some other object is "equal to" this one.failure()Returns the value of thefailurerecord component.final inthashCode()Returns a hash code value for this object.booleanbooleanbooleanbooleanmissing()Returns the value of themissingrecord component.success()Returns the value of thesuccessrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
OConsensusSuccess
public OConsensusSuccess() -
OConsensusSuccess
public OConsensusSuccess(boolean applied) -
OConsensusSuccess
-
OConsensusSuccess
-
OConsensusSuccess
-
OConsensusSuccess
public OConsensusSuccess(ODistributedMessage success, OTransactionIdPromise failure, boolean missing, boolean applied) Creates an instance of aOConsensusSuccessrecord class.- Parameters:
success- the value for thesuccessrecord componentfailure- the value for thefailurerecord componentmissing- the value for themissingrecord componentapplied- the value for theappliedrecord component
-
-
Method Details
-
isSuccess
public boolean isSuccess() -
isFailure
public boolean isFailure() -
isFinished
public boolean isFinished() -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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 '=='. -
success
Returns the value of thesuccessrecord component.- Returns:
- the value of the
successrecord component
-
failure
Returns the value of thefailurerecord component.- Returns:
- the value of the
failurerecord component
-
missing
public boolean missing()Returns the value of themissingrecord component.- Returns:
- the value of the
missingrecord component
-
applied
public boolean applied()Returns the value of theappliedrecord component.- Returns:
- the value of the
appliedrecord component
-