ByteBufUtil

public class ByteBufUtil

Class ByteBufUtil. Provides bytebufutil functionality for the Hytale server.

java.lang.Object > ByteBufUtil

Field Summary

before

final int before

Field before.

length

final int length

Field length.

after

final int after

Field after.

bytes

final byte[] bytes

Field bytes.

wordsInUse

final int wordsInUse

Field wordsInUse.

words

final long[] words

Field words.

Method Detail

writeUTF

static void writeUTF (@Nonnull final ByteBuf buf, @Nonnull final String string)

Method writeUTF.

Parameters:
@Nonnull final ByteBuf buf
@Nonnull final String string

readUTF

static String readUTF (@Nonnull final ByteBuf buf)

Method readUTF.

Parameters:
@Nonnull final ByteBuf buf

writeByteArray

static void writeByteArray (@Nonnull final ByteBuf buf, @Nonnull final byte[] arr)

Method writeByteArray.

Parameters:
@Nonnull final ByteBuf buf
@Nonnull final byte[] arr

readByteArray

static byte[] readByteArray (@Nonnull final ByteBuf buf)

Method readByteArray.

Parameters:
@Nonnull final ByteBuf buf

getBytesRelease

static byte[] getBytesRelease (@Nonnull final ByteBuf buf)

Method getBytesRelease.

Parameters:
@Nonnull final ByteBuf buf

writeNumber

static void writeNumber (@Nonnull final ByteBuf buf, final int bytes, final int value)

Method writeNumber.

Parameters:
@Nonnull final ByteBuf buf
final int bytes
final int value

readNumber

static int readNumber (@Nonnull final ByteBuf buf, final int bytes)

Method readNumber.

Parameters:
@Nonnull final ByteBuf buf
final int bytes

switch

public return switch (bytes)

Method switch.

Parameters:
bytes bytes

writeBitSet

static void writeBitSet (@Nonnull final ByteBuf buf, @Nonnull final BitSet bitset)

Method writeBitSet.

Parameters:
@Nonnull final ByteBuf buf
@Nonnull final BitSet bitset

readBitSet

static void readBitSet (@Nonnull final ByteBuf buf, @Nonnull final BitSet bitset)

Method readBitSet.

Parameters:
@Nonnull final ByteBuf buf
@Nonnull final BitSet bitset