public abstract class NetStreamPacker
extends java.lang.Object
Constructor and Description |
---|
NetStreamPacker() |
Modifier and Type | Method and Description |
---|---|
java.nio.ByteBuffer |
packMessage(java.nio.ByteBuffer buffer)
Pack the given ByteBuffer form its position to its capacity.
|
abstract java.nio.ByteBuffer |
packMessage(java.nio.ByteBuffer buffer,
int startIndex,
int endIndex)
Pack the given ByteBuffer from startIndex to endIdex
|
abstract java.nio.ByteBuffer |
packMessageSize(int capacity) |
public abstract java.nio.ByteBuffer packMessage(java.nio.ByteBuffer buffer, int startIndex, int endIndex)
buffer
- The buffer to pack/encodestartIndex
- the index at which the encoding starts in the bufferendIndex
- the index at which the encoding stopspublic java.nio.ByteBuffer packMessage(java.nio.ByteBuffer buffer)
buffer
- The buffer to pack/encodepublic abstract java.nio.ByteBuffer packMessageSize(int capacity)
capacity
-