Package com.jme3.network.base.protocol
Class LazyMessageBuffer
java.lang.Object
com.jme3.network.base.protocol.LazyMessageBuffer
- All Implemented Interfaces:
- MessageBuffer
A MessageBuffer implementation that will deserialize messages as they
  are returned instead of deserializing them as the data comes in.  This
  allows the individual messages to be processed before later messages
  are deserialized, thus allowing the serialization process itself to be
  altered mid-stream.
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionbooleanaddBytes(ByteBuffer buffer) Adds byte data to the message buffer.booleanReturns true if there is a message waiting in the buffer.Returns the next message in the buffer or null if there are no more messages in the buffer.
- 
Constructor Details- 
LazyMessageBuffer
 
- 
- 
Method Details- 
pollMessageReturns the next message in the buffer or null if there are no more messages in the buffer.- Specified by:
- pollMessagein interface- MessageBuffer
 
- 
hasMessagespublic boolean hasMessages()Returns true if there is a message waiting in the buffer.- Specified by:
- hasMessagesin interface- MessageBuffer
 
- 
addBytesAdds byte data to the message buffer. Returns true if there is a message waiting after this call.- Specified by:
- addBytesin interface- MessageBuffer
 
 
-