readBytes

static PacketByteBuf readBytes(ByteBuf buf, int length)

Wraps the newly created buf from {@code buf.readBytes} in a packet byte buf.

Return

the transferred bytes

See also

io.netty.buffer.ByteBuf

ByteBuf#readBytes(int)

Parameters

buf

the original buf

length

the number of bytes to transfer

Sources

jvm source
Link copied to clipboard