|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectucar.nc2.iosp.bufr.BitReader
public class BitReader
Helper for reading data that has been bit packed.
| Constructor Summary | |
|---|---|
BitReader(RandomAccessFile raf,
long startPos)
Constructor |
|
| Method Summary | |
|---|---|
long |
bits2UInt(int nb)
Read the next nb bits and return an Unsigned Long . |
long |
getPos()
|
static void |
main(java.lang.String[] args)
|
void |
setBitOffset(int bitOffset)
Position file at bitOffset from startPos |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public BitReader(RandomAccessFile raf,
long startPos)
throws java.io.IOException
raf - the RandomAccessFilestartPos - points to start of data in data section, in bytes
java.io.IOException - on read error| Method Detail |
|---|
public void setBitOffset(int bitOffset)
throws java.io.IOException
bitOffset - bit offset from starting position
java.io.IOException - on io error
public long bits2UInt(int nb)
throws java.io.IOException
nb - the number of bits to convert to int, must be <= 64.
java.io.IOException - on read error
public long getPos()
throws java.io.IOException
java.io.IOException
public static void main(java.lang.String[] args)
throws java.io.IOException
java.io.IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||