universal
Class NackWriteMessage

java.lang.Object
  |
  +--universal.Message
        |
        +--universal.WriteMessage
              |
              +--universal.NackWriteMessage
All Implemented Interfaces:
java.io.Serializable

public class NackWriteMessage
extends universal.WriteMessage

Used for creating NackWriteMessage.
A NackWriteMessage is sent during the consensus by the replicated servers
to the leader to say that they don't acknowledge the Write message that the leader has sent.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class universal.WriteMessage
batchno, Kpj, roundno, value
 
Fields inherited from class universal.Message
ACK_READ_MSG, ACK_WRITE_MSG, AM_ALIVE_MSG, mid, msgType, NACK_READ_MSG, NACK_WRITE_MSG, READ_MSG, senderid, WRITE_MSG
 
Constructor Summary
NackWriteMessage(int batchno, int roundno)
          The constructor
 
Method Summary
static universal.WriteMessage decode(java.io.DataInputStream dis)
          When you want to decode a NackWriteMessage you have to call the decode function of the superclass Message.
 byte[] encode()
          When you want to encode a NackWriteMessage you should call this function.
 boolean equals(java.lang.Object obj)
          Compares two objects for equality.
 java.lang.String toString()
           
 
Methods inherited from class universal.Message
decode, msgId, msgType
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

NackWriteMessage

public NackWriteMessage(int batchno,
                        int roundno)
The constructor

Parameters:
batchno - the place in the total order for which the consensus is actually made
roundno - the round number for this consensus.
Method Detail

decode

public static universal.WriteMessage decode(java.io.DataInputStream dis)
When you want to decode a NackWriteMessage you have to call the decode function of the superclass Message.


encode

public byte[] encode()
When you want to encode a NackWriteMessage you should call this function.

Overrides:
encode in class universal.WriteMessage

equals

public boolean equals(java.lang.Object obj)
Compares two objects for equality. Returns a boolean that indicates whether this object is equivalent to the specified object. This method is used when an object is stored in a hashtable.

Overrides:
equals in class universal.WriteMessage
Parameters:
obj - the Object to compare with
Returns:
true if these Objects are equal; false otherwise.
See Also:
Hashtable

toString

public java.lang.String toString()
Overrides:
toString in class universal.WriteMessage