Package io.datarouter.bytes
Class ByteTool
java.lang.Object
io.datarouter.bytes.ByteTool
public class ByteTool extends Object
-
Field Summary
Fields Modifier and Type Field Description static byte[][]EMPTY_ARRAY_2 -
Constructor Summary
Constructors Constructor Description ByteTool() -
Method Summary
Modifier and Type Method Description static byte[]concat(byte[]... arrays)static byte[]concat(List<byte[]> arrays)static byte[]copyOfRange(byte[] original, int from, int length)static byte[]flipToAndFromComparableByteArray(byte[] ins)static byte[]flipToAndFromComparableByteArray(byte[] ins, int offset, int length)static bytegetComparableByte(byte value)static byte[]padPrefix(byte[] in, int finalWidth)static inttotalLength(byte[]... arrays)static inttotalLength(List<byte[]> arrays)static byte[]unsignedIncrement(byte[] in)static byte[]unsignedIncrementOverflowToNull(byte[] in)
-
Field Details
-
EMPTY_ARRAY_2
public static final byte[][] EMPTY_ARRAY_2
-
-
Constructor Details
-
ByteTool
public ByteTool()
-
-
Method Details
-
getComparableByte
public static byte getComparableByte(byte value) -
flipToAndFromComparableByteArray
public static byte[] flipToAndFromComparableByteArray(byte[] ins) -
flipToAndFromComparableByteArray
public static byte[] flipToAndFromComparableByteArray(byte[] ins, int offset, int length) -
copyOfRange
public static byte[] copyOfRange(byte[] original, int from, int length) -
unsignedIncrement
public static byte[] unsignedIncrement(byte[] in) -
unsignedIncrementOverflowToNull
public static byte[] unsignedIncrementOverflowToNull(byte[] in) -
totalLength
public static int totalLength(byte[]... arrays) -
totalLength
-
concat
public static byte[] concat(byte[]... arrays) -
concat
-
padPrefix
public static byte[] padPrefix(byte[] in, int finalWidth)
-