org.objectweb.dream.protocol.utobcast.message
Class UTOBcastChunkImpl

java.lang.Object
  extended byorg.objectweb.dream.message.AbstractChunk
      extended byorg.objectweb.dream.protocol.utobcast.message.UTOBcastChunkImpl
All Implemented Interfaces:
Chunk, Cloneable, Recyclable, SequenceNumberChunk, Serializable, UTOBcastChunk

public class UTOBcastChunkImpl
extends AbstractChunk
implements UTOBcastChunk

Basic implementation of the UTOBcastChunkinterface.

See Also:
Serialized Form

Field Summary
protected  Process processFrom
          The process that sent this chunk.
protected  Process processTo
          The process to which this chunk is destinated.
protected  long sn
          The sequence number of this message.
protected  byte utoBcastMessageType
          The type of the message that contains this chunk.
 
Fields inherited from interface org.objectweb.dream.protocol.utobcast.message.UTOBcastChunk
ACK, BAK, DAT, DEFAULT_NAME, REP, TYPE, UPD, UTO
 
Constructor Summary
UTOBcastChunkImpl()
           
 
Method Summary
 Process getProcessFrom()
          Returns the process that sent this message.
 Process getProcessTo()
          Returns the process to which this message is destinated.
 long getSequenceNumber()
          Returns the sequence number of this message.
 ChunkType getType()
           
 byte getUTOBcastMessageType()
          Returns the UTOBcast type of the message that contains this chunk.
 void recycle()
           
 void setProcessFrom(Process process)
          Sets the process that sent this message.
 void setProcessTo(Process process)
          Sets the process to which this message is destinated.
 void setSequenceNumber(long sn)
          Sets the sequence number of this message.
 void setUTOBcastMessageType(byte type)
          Sets the UTOBcast type of the message that contains this chunk.
 void transfertState(Chunk newInstance)
           
 
Methods inherited from class org.objectweb.dream.message.AbstractChunk
getMessageManagerId, setMessageManagerId
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

utoBcastMessageType

protected byte utoBcastMessageType
The type of the message that contains this chunk.


processFrom

protected Process processFrom
The process that sent this chunk.


processTo

protected Process processTo
The process to which this chunk is destinated.


sn

protected long sn
The sequence number of this message.

Constructor Detail

UTOBcastChunkImpl

public UTOBcastChunkImpl()
Method Detail

getUTOBcastMessageType

public byte getUTOBcastMessageType()
Description copied from interface: UTOBcastChunk
Returns the UTOBcast type of the message that contains this chunk.

Specified by:
getUTOBcastMessageType in interface UTOBcastChunk
Returns:
  • 0 for DAT messages
  • 1 for ACK messages
  • 2 for REP messages
  • 3 for UTO messages
  • 4 for UPD messages
  • 5 for BACK messages
See Also:
UTOBcastChunk.getUTOBcastMessageType()

setUTOBcastMessageType

public void setUTOBcastMessageType(byte type)
Description copied from interface: UTOBcastChunk
Sets the UTOBcast type of the message that contains this chunk. This type can be

Specified by:
setUTOBcastMessageType in interface UTOBcastChunk
Parameters:
type - the UTOBcast type to set.
See Also:
UTOBcastChunk.setUTOBcastMessageType(byte)

getProcessFrom

public Process getProcessFrom()
Description copied from interface: UTOBcastChunk
Returns the process that sent this message.

Specified by:
getProcessFrom in interface UTOBcastChunk
Returns:
the process that sent this message.
See Also:
UTOBcastChunk.getProcessFrom()

setProcessFrom

public void setProcessFrom(Process process)
Description copied from interface: UTOBcastChunk
Sets the process that sent this message.

Specified by:
setProcessFrom in interface UTOBcastChunk
Parameters:
process - the process that sent this message.
See Also:
UTOBcastChunk.setProcessFrom(Process)

getProcessTo

public Process getProcessTo()
Description copied from interface: UTOBcastChunk
Returns the process to which this message is destinated.

Specified by:
getProcessTo in interface UTOBcastChunk
Returns:
the process to which this message is destinated.
See Also:
UTOBcastChunk.getProcessTo()

setProcessTo

public void setProcessTo(Process process)
Description copied from interface: UTOBcastChunk
Sets the process to which this message is destinated.

Specified by:
setProcessTo in interface UTOBcastChunk
Parameters:
process - the process to which this message is destinated.
See Also:
UTOBcastChunk.setProcessTo(Process)

setSequenceNumber

public void setSequenceNumber(long sn)
Description copied from interface: SequenceNumberChunk
Sets the sequence number of this message.

Specified by:
setSequenceNumber in interface SequenceNumberChunk
Parameters:
sn - the sequence number to set.
See Also:
SequenceNumberChunk.setSequenceNumber(long)

getSequenceNumber

public long getSequenceNumber()
Description copied from interface: SequenceNumberChunk
Returns the sequence number of this message.

Specified by:
getSequenceNumber in interface SequenceNumberChunk
Returns:
the sequence number of this message.
See Also:
SequenceNumberChunk.getSequenceNumber()

getType

public ChunkType getType()
Specified by:
getType in interface Chunk
See Also:
Chunk.getType()

transfertState

public void transfertState(Chunk newInstance)
Specified by:
transfertState in interface Chunk
See Also:
Chunk.transfertState(Chunk)

recycle

public void recycle()
Specified by:
recycle in interface Recyclable
See Also:
Recyclable.recycle()


Copyright © 2003, 2004 - INRIA Rhone-Alpes - All Rights Reserved.