de.javawi.jstun.util
Class Utility

java.lang.Object
  extended by de.javawi.jstun.util.Utility

public class Utility
extends Object


Constructor Summary
Utility()
           
 
Method Summary
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)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Utility

public Utility()
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