Interface GroupMembership<M extends GroupMember>
- Type Parameters:
M- the group member type
- All Superinterfaces:
GroupMembership<M>
- All Known Implementing Classes:
ViewMembership
Group membership whose coordinator is identified by its index in the membership.
- Author:
- Paul Ferraro
-
Method Summary
Modifier and TypeMethodDescriptiondefault MReturns the coordinator of this group membership.intReturns the index of the group coordinator.static <M extends GroupMember>
GroupMembership<M> singleton(M member) Returns a singleton group membership.Methods inherited from interface GroupMembership
getMembers
-
Method Details
-
getCoordinatorIndex
int getCoordinatorIndex()Returns the index of the group coordinator.- Returns:
- the index of the group coordinator.
-
getCoordinator
Description copied from interface:GroupMembershipReturns the coordinator of this group membership. All members of this membership will always agree on which member is the coordinator.- Specified by:
getCoordinatorin interfaceGroupMembership<M extends GroupMember>- Returns:
- the group coordinator
-
singleton
Returns a singleton group membership.- Type Parameters:
M- the member type- Parameters:
member- the single group member- Returns:
- a singleton group membership.
-