public class ByteBufferUtil extends Object
| Constructor and Description |
|---|
ByteBufferUtil() |
| Modifier and Type | Method and Description |
|---|---|
static String |
bytesToHex(ByteBuffer bytes) |
static int |
compare(ByteBuffer b1,
ByteBuffer b2)
Compares two
ByteBuffers according to their byte order (and not the byte value). |
static boolean |
isSmallerOrEqualThan(ByteBuffer a,
ByteBuffer b)
Compares two
ByteBuffers and checks whether the first ByteBuffer is smaller than or equal to the second. |
static boolean |
isSmallerThan(ByteBuffer a,
ByteBuffer b)
Compares two
ByteBuffers and checks whether the first ByteBuffer is smaller than the second. |
static ByteBuffer |
oneByteBuffer(int len) |
static String |
toString(ByteBuffer b,
String separator) |
static ByteBuffer |
zeroByteBuffer(int len) |
public static final ByteBuffer zeroByteBuffer(int len)
public static final ByteBuffer oneByteBuffer(int len)
public static final boolean isSmallerThan(ByteBuffer a, ByteBuffer b)
ByteBuffers and checks whether the first ByteBuffer is smaller than the second.a - First ByteBufferb - Second ByteBufferpublic static boolean isSmallerOrEqualThan(ByteBuffer a, ByteBuffer b)
ByteBuffers and checks whether the first ByteBuffer is smaller than or equal to the second.a - First ByteBufferb - Second ByteBufferpublic static final int compare(ByteBuffer b1, ByteBuffer b2)
ByteBuffers according to their byte order (and not the byte value).
b1 - First ByteBufferb2 - Second ByteBufferpublic static String bytesToHex(ByteBuffer bytes)
public static final String toString(ByteBuffer b, String separator)
Copyright © 2012–2015. All rights reserved.