public class NettyByteBufAdapter
extends io.netty.buffer.AbstractByteBuf
Note that as streams usually don't support seeking, this implementation will ignore all indexing in the byte buffer.
| Modifier and Type | Method and Description |
|---|---|
protected byte |
_getByte(int paramInt) |
protected int |
_getInt(int paramInt) |
protected long |
_getLong(int paramInt) |
protected short |
_getShort(int paramInt) |
protected int |
_getUnsignedMedium(int paramInt) |
protected void |
_setByte(int index,
int value) |
protected void |
_setInt(int index,
int value) |
protected void |
_setLong(int index,
long value) |
protected void |
_setMedium(int index,
int value) |
protected void |
_setShort(int index,
int value) |
io.netty.buffer.ByteBufAllocator |
alloc() |
byte[] |
array() |
int |
arrayOffset() |
int |
capacity() |
io.netty.buffer.ByteBuf |
capacity(int paramInt) |
io.netty.buffer.ByteBuf |
copy(int index,
int length) |
io.netty.buffer.ByteBuf |
getBytes(int index,
byte[] dst,
int dstIndex,
int length) |
io.netty.buffer.ByteBuf |
getBytes(int index,
ByteBuffer dst) |
io.netty.buffer.ByteBuf |
getBytes(int index,
io.netty.buffer.ByteBuf dst,
int dstIndex,
int length) |
int |
getBytes(int index,
GatheringByteChannel out,
int length) |
io.netty.buffer.ByteBuf |
getBytes(int index,
OutputStream dst,
int length) |
boolean |
hasArray() |
boolean |
hasMemoryAddress() |
ByteBuffer |
internalNioBuffer(int paramInt1,
int paramInt2) |
boolean |
isDirect() |
long |
memoryAddress() |
ByteBuffer |
nioBuffer(int paramInt1,
int paramInt2) |
int |
nioBufferCount() |
ByteBuffer[] |
nioBuffers(int paramInt1,
int paramInt2) |
ByteOrder |
order() |
static io.netty.buffer.ByteBuf |
packetReader(DataInputStream input)
Construct a new Minecraft packet serializer using the current byte buf adapter.
|
static io.netty.buffer.ByteBuf |
packetWriter(DataOutputStream output)
Construct a new Minecraft packet deserializer using the current byte buf adapter.
|
int |
refCnt() |
boolean |
release() |
boolean |
release(int paramInt) |
io.netty.buffer.ByteBuf |
retain() |
io.netty.buffer.ByteBuf |
retain(int paramInt) |
io.netty.buffer.ByteBuf |
setBytes(int index,
byte[] src,
int srcIndex,
int length) |
io.netty.buffer.ByteBuf |
setBytes(int index,
ByteBuffer src) |
io.netty.buffer.ByteBuf |
setBytes(int index,
io.netty.buffer.ByteBuf src,
int srcIndex,
int length) |
int |
setBytes(int index,
InputStream in,
int length) |
int |
setBytes(int index,
ScatteringByteChannel in,
int length) |
io.netty.buffer.ByteBuf |
unwrap() |
adjustMarkers, bytesBefore, bytesBefore, bytesBefore, checkDstIndex, checkIndex, checkIndex, checkReadableBytes, checkSrcIndex, clear, compareTo, copy, discardReadBytes, discardSomeReadBytes, duplicate, ensureAccessible, ensureWritable, ensureWritable, equals, forEachByte, forEachByte, forEachByteDesc, forEachByteDesc, getBoolean, getByte, getBytes, getBytes, getBytes, getChar, getDouble, getFloat, getInt, getLong, getMedium, getShort, getUnsignedByte, getUnsignedInt, getUnsignedMedium, getUnsignedShort, hashCode, indexOf, isReadable, isReadable, isWritable, isWritable, markReaderIndex, markWriterIndex, maxCapacity, maxCapacity, maxWritableBytes, newSwappedByteBuf, nioBuffer, nioBuffers, order, readableBytes, readBoolean, readByte, readBytes, readBytes, readBytes, readBytes, readBytes, readBytes, readBytes, readBytes, readBytes, readChar, readDouble, readerIndex, readerIndex, readFloat, readInt, readLong, readMedium, readShort, readSlice, readUnsignedByte, readUnsignedInt, readUnsignedMedium, readUnsignedShort, resetReaderIndex, resetWriterIndex, setBoolean, setByte, setBytes, setBytes, setBytes, setChar, setDouble, setFloat, setIndex, setInt, setLong, setMedium, setShort, setZero, skipBytes, slice, slice, toString, toString, toString, writableBytes, writeBoolean, writeByte, writeBytes, writeBytes, writeBytes, writeBytes, writeBytes, writeBytes, writeBytes, writeBytes, writeChar, writeDouble, writeFloat, writeInt, writeLong, writeMedium, writerIndex, writerIndex, writeShort, writeZeropublic static io.netty.buffer.ByteBuf packetReader(DataInputStream input)
input - - the input stream.public static io.netty.buffer.ByteBuf packetWriter(DataOutputStream output)
output - - the output stream.public int refCnt()
public boolean release()
public boolean release(int paramInt)
protected byte _getByte(int paramInt)
_getByte in class io.netty.buffer.AbstractByteBufprotected short _getShort(int paramInt)
_getShort in class io.netty.buffer.AbstractByteBufprotected int _getUnsignedMedium(int paramInt)
_getUnsignedMedium in class io.netty.buffer.AbstractByteBufprotected int _getInt(int paramInt)
_getInt in class io.netty.buffer.AbstractByteBufprotected long _getLong(int paramInt)
_getLong in class io.netty.buffer.AbstractByteBufprotected void _setByte(int index,
int value)
_setByte in class io.netty.buffer.AbstractByteBufprotected void _setShort(int index,
int value)
_setShort in class io.netty.buffer.AbstractByteBufprotected void _setMedium(int index,
int value)
_setMedium in class io.netty.buffer.AbstractByteBufprotected void _setInt(int index,
int value)
_setInt in class io.netty.buffer.AbstractByteBufprotected void _setLong(int index,
long value)
_setLong in class io.netty.buffer.AbstractByteBufpublic int capacity()
capacity in class io.netty.buffer.ByteBufpublic io.netty.buffer.ByteBuf capacity(int paramInt)
capacity in class io.netty.buffer.ByteBufpublic io.netty.buffer.ByteBufAllocator alloc()
alloc in class io.netty.buffer.ByteBufpublic ByteOrder order()
order in class io.netty.buffer.ByteBufpublic io.netty.buffer.ByteBuf unwrap()
unwrap in class io.netty.buffer.ByteBufpublic boolean isDirect()
isDirect in class io.netty.buffer.ByteBufpublic io.netty.buffer.ByteBuf getBytes(int index,
io.netty.buffer.ByteBuf dst,
int dstIndex,
int length)
getBytes in class io.netty.buffer.ByteBufpublic io.netty.buffer.ByteBuf getBytes(int index,
byte[] dst,
int dstIndex,
int length)
getBytes in class io.netty.buffer.ByteBufpublic io.netty.buffer.ByteBuf getBytes(int index,
ByteBuffer dst)
getBytes in class io.netty.buffer.ByteBufpublic io.netty.buffer.ByteBuf getBytes(int index,
OutputStream dst,
int length)
throws IOException
getBytes in class io.netty.buffer.ByteBufIOExceptionpublic int getBytes(int index,
GatheringByteChannel out,
int length)
throws IOException
getBytes in class io.netty.buffer.ByteBufIOExceptionpublic io.netty.buffer.ByteBuf setBytes(int index,
io.netty.buffer.ByteBuf src,
int srcIndex,
int length)
setBytes in class io.netty.buffer.ByteBufpublic io.netty.buffer.ByteBuf setBytes(int index,
byte[] src,
int srcIndex,
int length)
setBytes in class io.netty.buffer.ByteBufpublic io.netty.buffer.ByteBuf setBytes(int index,
ByteBuffer src)
setBytes in class io.netty.buffer.ByteBufpublic int setBytes(int index,
InputStream in,
int length)
throws IOException
setBytes in class io.netty.buffer.ByteBufIOExceptionpublic int setBytes(int index,
ScatteringByteChannel in,
int length)
throws IOException
setBytes in class io.netty.buffer.ByteBufIOExceptionpublic io.netty.buffer.ByteBuf copy(int index,
int length)
copy in class io.netty.buffer.ByteBufpublic int nioBufferCount()
nioBufferCount in class io.netty.buffer.ByteBufpublic ByteBuffer nioBuffer(int paramInt1, int paramInt2)
nioBuffer in class io.netty.buffer.ByteBufpublic ByteBuffer internalNioBuffer(int paramInt1, int paramInt2)
internalNioBuffer in class io.netty.buffer.ByteBufpublic ByteBuffer[] nioBuffers(int paramInt1, int paramInt2)
nioBuffers in class io.netty.buffer.ByteBufpublic boolean hasArray()
hasArray in class io.netty.buffer.ByteBufpublic byte[] array()
array in class io.netty.buffer.ByteBufpublic int arrayOffset()
arrayOffset in class io.netty.buffer.ByteBufpublic boolean hasMemoryAddress()
hasMemoryAddress in class io.netty.buffer.ByteBufpublic long memoryAddress()
memoryAddress in class io.netty.buffer.ByteBufpublic io.netty.buffer.ByteBuf retain(int paramInt)
retain in interface io.netty.util.ReferenceCountedretain in class io.netty.buffer.ByteBufpublic io.netty.buffer.ByteBuf retain()
retain in interface io.netty.util.ReferenceCountedretain in class io.netty.buffer.ByteBufCopyright © 2012–2017 Comphenix and dmulloy2. Licensed under the GNU GPL v2.