Package bftsmart.tom.leaderchange
Class CollectData
- java.lang.Object
-
- bftsmart.tom.leaderchange.CollectData
-
- All Implemented Interfaces:
java.io.Externalizable,java.io.Serializable
public class CollectData extends java.lang.Object implements java.io.ExternalizableThis class represents a COLLECT object with the information about the running consensus- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description CollectData()Empty constructorCollectData(int pid, int cid, int ets, TimestampValuePair quorumWrites, java.util.HashSet<TimestampValuePair> writeSet)Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)intgetCid()Get consensus idintgetEts()Get consensus ETSintgetPid()Get process idTimestampValuePairgetQuorumWrites()Get value received from a Byzantine quorum of WRITEsjava.util.HashSet<TimestampValuePair>getWriteSet()Get set of values written by the replicainthashCode()voidreadExternal(java.io.ObjectInput in)voidwriteExternal(java.io.ObjectOutput out)
-
-
-
Constructor Detail
-
CollectData
public CollectData()
Empty constructor
-
CollectData
public CollectData(int pid, int cid, int ets, TimestampValuePair quorumWrites, java.util.HashSet<TimestampValuePair> writeSet)Constructor- Parameters:
pid- process idcid- Consensus idets- Consensus ETSquorumWrites- last value received from a Byzantine quorum of WRITEswriteSet- values written by the replica
-
-
Method Detail
-
getCid
public int getCid()
Get consensus id- Returns:
- consensus id
-
getEts
public int getEts()
Get consensus ETS- Returns:
- consensus ETS
-
getPid
public int getPid()
Get process id- Returns:
- process id
-
getQuorumWrites
public TimestampValuePair getQuorumWrites()
Get value received from a Byzantine quorum of WRITEs- Returns:
- value received from a Byzantine quorum of WRITEs
-
getWriteSet
public java.util.HashSet<TimestampValuePair> getWriteSet()
Get set of values written by the replica- Returns:
- set of values written by the replica
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
writeExternal
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException- Specified by:
writeExternalin interfacejava.io.Externalizable- Throws:
java.io.IOException
-
readExternal
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException- Specified by:
readExternalin interfacejava.io.Externalizable- Throws:
java.io.IOExceptionjava.lang.ClassNotFoundException
-
-