Package org.onosproject.store.service
Class PartitionInfo
- java.lang.Object
-
- org.onosproject.store.service.PartitionInfo
-
public class PartitionInfo extends java.lang.Object
Contains information about a database partition.
-
-
Constructor Summary
Constructors Constructor Description PartitionInfo(PartitionId partitionId, long term, java.util.List<java.lang.String> members, java.lang.String leader)
Class constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PartitionId
id()
Returns the partition ID.java.lang.String
leader()
Returns the partition leader.java.util.List<java.lang.String>
members()
Returns the list of partition members.long
term()
Returns the term number.
-
-
-
Constructor Detail
-
PartitionInfo
public PartitionInfo(PartitionId partitionId, long term, java.util.List<java.lang.String> members, java.lang.String leader)
Class constructor.- Parameters:
partitionId
- partition identifierterm
- term numbermembers
- partition membersleader
- leader name
-
-
Method Detail
-
id
public PartitionId id()
Returns the partition ID.- Returns:
- partition ID
-
term
public long term()
Returns the term number.- Returns:
- term number
-
members
public java.util.List<java.lang.String> members()
Returns the list of partition members.- Returns:
- partition members
-
leader
public java.lang.String leader()
Returns the partition leader.- Returns:
- partition leader
-
-