|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.hermit.utils.Bitwise
public class Bitwise
A set of bit-twiddling utilities.
Method Summary | |
---|---|
static int |
bitrev(int j,
int n)
Reverse the lowest n bits of j. |
static boolean |
isPowerOf2(int n)
Returns true if the argument is power of 2. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static final boolean isPowerOf2(int n)
n
- The number to test.
public static final int bitrev(int j, int n)
j
- Number to be reversed.n
- Number of low-order bits of j which are significant
and to be reversed.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |