Package org.jgroups.protocols
Class Frag3Header
java.lang.Object
org.jgroups.Header
org.jgroups.protocols.Frag3Header
- All Implemented Interfaces:
Constructable<Header>,SizeStreamable,Streamable
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected intprotected intprotected booleanprotected intprotected intprotected int -
Constructor Summary
ConstructorsConstructorDescriptionFrag3Header(int id, int frag_id, int num_frags) Frag3Header(int id, int frag_id, int num_frags, int original_length, int offset) -
Method Summary
Modifier and TypeMethodDescriptioncreate()Creates an instance of the class implementing this interfaceintshortReturns the magic-ID.intintintbooleanneedsDeserialization(boolean f) voidRead the state of the current object (including superclasses) from instream Note that the input stream must not be closedintReturns the size (in bytes) of the marshalled objectsetFragId(int frag_id) setNumFrags(int n) setOffset(int offset) setOriginalLength(int l) toString()voidwriteTo(DataOutput out) Write the entire state of the current object (including superclasses) to outstream.
-
Field Details
-
id
protected int id -
frag_id
protected int frag_id -
num_frags
protected int num_frags -
original_length
protected int original_length -
offset
protected int offset -
needs_deserialization
protected boolean needs_deserialization
-
-
Constructor Details
-
Frag3Header
public Frag3Header() -
Frag3Header
public Frag3Header(int id, int frag_id, int num_frags) -
Frag3Header
public Frag3Header(int id, int frag_id, int num_frags, int original_length, int offset)
-
-
Method Details
-
getMagicId
public short getMagicId()Description copied from class:HeaderReturns the magic-ID. If defined in jg-magic-map.xml, the IDs need to be the same- Specified by:
getMagicIdin classHeader
-
create
Description copied from interface:ConstructableCreates an instance of the class implementing this interface -
getFragId
public int getFragId() -
setFragId
-
getNumFrags
public int getNumFrags() -
setNumFrags
-
getOriginalLength
public int getOriginalLength() -
setOriginalLength
-
getOffset
public int getOffset() -
setOffset
-
needsDeserialization
public boolean needsDeserialization() -
needsDeserialization
-
toString
-
writeTo
Description copied from interface:StreamableWrite the entire state of the current object (including superclasses) to outstream. Note that the output stream must not be closed- Throws:
IOException
-
serializedSize
public int serializedSize()Description copied from interface:SizeStreamableReturns the size (in bytes) of the marshalled object -
readFrom
Description copied from interface:StreamableRead the state of the current object (including superclasses) from instream Note that the input stream must not be closed- Throws:
IOException
-