|
JAPI 0.9.0 Yet another Java API API Documentation |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.japi.util.EndianConverter
public class EndianConverter
Class to convert data from little endian to big endian and vice versa. Since the conversion is symmetric, there are no special conversion methods, just generic ones, e.g. the same method is used to convert a little endian integer to a big endian integer and vice versa.
Method Summary | |
---|---|
static boolean |
swapEndianess(boolean b)
Convert a boolean. |
static byte |
swapEndianess(byte b)
Convert a byte. |
static char |
swapEndianess(char c)
Convert a char. |
static double |
swapEndianess(double d)
Convert a double. |
static float |
swapEndianess(float f)
Convert a float. |
static int |
swapEndianess(int i)
Convert an int. |
static long |
swapEndianess(long l)
Convert a long. |
static short |
swapEndianess(short s)
Convert a short. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static final double swapEndianess(double d)
d
- double to convert
public static final float swapEndianess(float f)
f
- float to convert
public static final long swapEndianess(long l)
l
- long to convert
public static final int swapEndianess(int i)
i
- int to convert
public static final char swapEndianess(char c)
c
- char to convert
public static final short swapEndianess(short s)
s
- short to convert
public static final byte swapEndianess(byte b)
b
- byte to convert
public static final boolean swapEndianess(boolean b)
b
- boolean to convert
|
JAPI Yet another Java API API Documentation |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |