Package io.atomix.primitive.partition
Class PrimaryElectionEvent
java.lang.Object
io.atomix.utils.event.AbstractEvent<PrimaryElectionEvent.Type,PrimaryTerm>
io.atomix.primitive.partition.PrimaryElectionEvent
- All Implemented Interfaces:
io.atomix.utils.event.Event<PrimaryElectionEvent.Type,PrimaryTerm>
public class PrimaryElectionEvent extends io.atomix.utils.event.AbstractEvent<PrimaryElectionEvent.Type,PrimaryTerm>
Primary election event.
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classPrimaryElectionEvent.TypeReturns the election event type. -
Constructor Summary
Constructors Constructor Description PrimaryElectionEvent(PrimaryElectionEvent.Type type, PartitionId partitionId, PrimaryTerm subject) -
Method Summary
Modifier and Type Method Description PartitionIdpartitionId()Returns the partition ID.PrimaryTermterm()Returns the election term.StringtoString()
-
Constructor Details
-
PrimaryElectionEvent
public PrimaryElectionEvent(PrimaryElectionEvent.Type type, PartitionId partitionId, PrimaryTerm subject)
-
-
Method Details
-
partitionId
Returns the partition ID.- Returns:
- the election partition
-
term
Returns the election term.- Returns:
- the election term
-
toString
- Overrides:
toStringin classio.atomix.utils.event.AbstractEvent<PrimaryElectionEvent.Type,PrimaryTerm>
-