public final class CPGroupInfo extends Object implements CPGroup, IdentifiedDataSerializable
CPGroup.CPGroupStatus
DEFAULT_GROUP_NAME, METADATA_CP_GROUP_NAME
Constructor and Description |
---|
CPGroupInfo() |
CPGroupInfo(RaftGroupId id,
Collection<CPMemberInfo> members) |
Modifier and Type | Method and Description |
---|---|
boolean |
applyMembershipChange(CPMemberInfo leaving,
CPMemberInfo joining,
long expectedMembersCommitIndex,
long newMembersCommitIndex) |
boolean |
containsMember(CPMemberInfo member) |
boolean |
forceSetDestroyed() |
int |
getFactoryId()
Returns DataSerializableFactory factory ID for this class.
|
int |
getId()
Returns type identifier for this class.
|
long |
getMembersCommitIndex() |
RaftGroupId |
id()
Returns unique id of the CP group
|
int |
initialMemberCount() |
Collection<CPMember> |
initialMembers() |
int |
memberCount() |
Collection<CPMemberInfo> |
memberImpls() |
Collection<CPMember> |
members()
Returns current members of the CP group
|
CPMemberInfo[] |
membersArray() |
String |
name() |
void |
readData(ObjectDataInput in)
Reads fields from the input stream
|
boolean |
setDestroyed() |
boolean |
setDestroying() |
CPGroup.CPGroupStatus |
status()
Returns status of the CP group
|
String |
toString() |
void |
writeData(ObjectDataOutput out)
Writes object fields to output stream
|
public CPGroupInfo()
public CPGroupInfo(RaftGroupId id, Collection<CPMemberInfo> members)
public RaftGroupId id()
CPGroup
public String name()
public int initialMemberCount()
public Collection<CPMember> members()
CPGroup
public Collection<CPMemberInfo> memberImpls()
public Collection<CPMember> initialMembers()
public boolean containsMember(CPMemberInfo member)
public int memberCount()
public CPGroup.CPGroupStatus status()
CPGroup
public boolean setDestroying()
public boolean setDestroyed()
public boolean forceSetDestroyed()
public long getMembersCommitIndex()
public boolean applyMembershipChange(CPMemberInfo leaving, CPMemberInfo joining, long expectedMembersCommitIndex, long newMembersCommitIndex)
public CPMemberInfo[] membersArray()
public void writeData(ObjectDataOutput out) throws IOException
DataSerializable
writeData
in interface DataSerializable
out
- outputIOException
- if an I/O error occurs. In particular,
an IOException
may be thrown if the
output stream has been closed.public void readData(ObjectDataInput in) throws IOException
DataSerializable
readData
in interface DataSerializable
in
- inputIOException
- if an I/O error occurs. In particular,
an IOException
may be thrown if the
input stream has been closed.public int getFactoryId()
IdentifiedDataSerializable
getFactoryId
in interface IdentifiedDataSerializable
public int getId()
IdentifiedDataSerializable
getId
in interface IdentifiedDataSerializable
Copyright © 2022 Hazelcast, Inc.. All Rights Reserved.