com.neeve.pkt
Class PktBodyFixed

java.lang.Object
  extended by com.neeve.util.UtlListElement
      extended by com.neeve.pkt.PktSerializable
          extended by com.neeve.pkt.PktBody
              extended by com.neeve.pkt.PktBodyFixed
All Implemented Interfaces:
com.neeve.io.IOElasticBuffer.Initializer, com.neeve.io.IOElasticBuffer.Sizer

public abstract class PktBodyFixed
extends PktBody

Base class for packet bodies of fixed length.

This class represents a fixed length packet body. Packet bodies that have fixed length content should extend from this class. When created, this class instantiates and stores a buffer to store the body contents. This buffer is of a fixed length equal to the total (fixed) length of the body contents. The packet body implementation should index the individual elements of the body into this buffer and use absolute setter and getter methods to set and get body element values.

Threading:
Packet bodies are not safe for concurrent access by multiple threads.

Nested Class Summary
 
Nested classes/interfaces inherited from class com.neeve.pkt.PktSerializable
PktSerializable.DeserializeContext, PktSerializable.SerializeContext
 
Field Summary
 
Fields inherited from class com.neeve.util.UtlListElement
count, head, next, prev
 
Method Summary
 int doGetSerializedLength()
          Implementation of PktBody.doGetSerializedLength() This method returns the fixed length of the body contents.
 
Methods inherited from class com.neeve.pkt.PktBody
deserialize, deserialize, deserialize, deserialize, deserialize, deserialize, deserialize, dump, getBuffer, getInitialBufferLength, getSerializedLength, getType, initializeBuffer, isNative, reset, serialize, serialize, serialize, serialize, serialize, serialize, serialize
 
Methods inherited from class com.neeve.pkt.PktSerializable
deserialize, getDeserializationPolicy, getSerializationPolicy, isValidDeserializationPolicy, isValidSerializationPolicy, serialize, setDeserializationPolicy, setSerializationPolicy
 
Methods inherited from class com.neeve.util.UtlListElement
count, insertAfter, insertBefore, isLinked, next, previous, unlink, wipe
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

doGetSerializedLength

public final int doGetSerializedLength()
Implementation of PktBody.doGetSerializedLength()

This method returns the fixed length of the body contents.



Copyright © 2016 Neeve Research, LLC. All Rights Reserved.