Package de.javawi.jstun.util
Class Utility
- java.lang.Object
-
- de.javawi.jstun.util.Utility
-
public class Utility extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description Utility()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static long
fourBytesToLong(byte[] value)
static byte[]
integerToFourBytes(int value)
static byte
integerToOneByte(int value)
static byte[]
integerToTwoBytes(int value)
static int
oneByteToInteger(byte value)
static int
twoBytesToInteger(byte[] value)
-
-
-
Method Detail
-
integerToOneByte
public static final byte integerToOneByte(int value) throws UtilityException
- Throws:
UtilityException
-
integerToTwoBytes
public static final byte[] integerToTwoBytes(int value) throws UtilityException
- Throws:
UtilityException
-
integerToFourBytes
public static final byte[] integerToFourBytes(int value) throws UtilityException
- Throws:
UtilityException
-
oneByteToInteger
public static final int oneByteToInteger(byte value) throws UtilityException
- Throws:
UtilityException
-
twoBytesToInteger
public static final int twoBytesToInteger(byte[] value) throws UtilityException
- Throws:
UtilityException
-
fourBytesToLong
public static final long fourBytesToLong(byte[] value) throws UtilityException
- Throws:
UtilityException
-
-