cgl.narada.transport.util
Class BytesUtil
java.lang.Object
cgl.narada.transport.util.BytesUtil
public class BytesUtil
- extends Object
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BytesUtil
public BytesUtil()
longToBytes
public static byte[] longToBytes(long l)
- Parameters:
l - long
- Returns:
- byte array for the given long integer
bytesToLong
public static long bytesToLong(byte[] bytes)
- Parameters:
bytes - array of size 8
- Returns:
- long integer converted
intToBytes
public static byte[] intToBytes(int i)
- Parameters:
i - int
- Returns:
- byte array for that given int
bytesToInt
public static int bytesToInt(byte[] buf)
- Parameters:
buf - byte array of size 4
- Returns:
- int converted from given byte array
For comments and suggestions please send
e-mail to
The NaradaBrokering Project