Interface CPGroupAvailabilityEvent


public interface CPGroupAvailabilityEvent
CPGroupAvailabilityEvent is published when a CP group's availability is decreased, or it has lost the majority completely.
Since:
4.1
  • Method Details

    • getGroupId

      CPGroupId getGroupId()
      Returns the id of the related CP group.
      Returns:
      CP group id
    • getGroupMembers

      Collection<CPMember> getGroupMembers()
      Returns the current members of the CP group.
      Returns:
      group members
    • getUnavailableMembers

      Collection<CPMember> getUnavailableMembers()
      Returns the unavailable members of the CP group.
      Returns:
      unavailable members
    • getMajority

      int getMajority()
      Returns the majority member count of the CP group. Simply it's (memberCount/2) + 1
      Returns:
      majority
    • isMajorityAvailable

      boolean isMajorityAvailable()
      Returns whether this group has the majority of its members available or not.
      Returns:
      true if the group still has the majority, false otherwise
    • isMetadataGroup

      boolean isMetadataGroup()
      Returns whether this is the METADATA CP group or not.
      Returns:
      true if the group is METADATA group, false otherwise