| Description | Hierarchy | Fields | Methods | Properties | 
type unaBitReader_abstract = class(unaObject)
Abstract base class for bit-reader. Provides methods like EOF(), nextBits() and skipBytes().
![]()  | 
function nextBits(numBits: unsigned = 8): uint32; | 
![]()  | 
function readBytes(numBytes: int; buf: pointer): uint32; | 
![]()  | 
function EOF(numBits: unsigned = 8): bool; virtual; abstract; | 
![]()  | 
function sbAt(at: int = -2): pointer; | 
![]()  | 
function sbLeft(): int; | 
![]()  | 
procedure BeforeDestruction(); override; | 
![]()  | 
procedure moveBitOfs(delta: int); | 
![]()  | 
procedure resetOutfillBuf(); | 
![]()  | 
procedure restart(); | 
![]()  | 
procedure setOutfillBuf(buf: pointer); | 
![]()  | 
procedure skipBytes(numBytes: unsigned); | 
![]()  | 
procedure skipToByte(); | 
![]()  | 
procedure doRestart(); virtual; | 
![]()  | 
procedure readSubBuf(reqSize: int = -1; append: bool = false); virtual; abstract; | 
![]()  | 
procedure sbAlloc(sz: int; append: bool); | 
![]()  | 
procedure sbAssign(v: pointer; sz: int); | 
![]()  | 
procedure sbIncrease(delta: int); | 
![]()  | 
property bitOfs: int64 read f_bitOfs; | 
![]()  | 
property bytesLeft: int read sbLeft; | 
![]()  | 
property isEOF: bool read getIsEOF; | 
![]()  | 
property outfill: bool read f_outfill write setOutfill; | 
![]()  | 
property outfillOfs: int read f_outfillOfs; | 
![]()  | 
function nextBits(numBits: unsigned = 8): uint32; | 
| 
 Reads given number of bits from buffer. 
 Parameters
 ReturnsBitstream from buffer.  | |
![]()  | 
function readBytes(numBytes: int; buf: pointer): uint32; | 
| 
 Reads given number of bytes into buffer. 
 Parameters
 ReturnsActual number of bytes read.  | |
![]()  | 
function EOF(numBits: unsigned = 8): bool; virtual; abstract; | 
| 
 Checks if end of file/stream is reached. 
 Parameters
 ReturnsTrue if given number of bits cannot be read or False otherwise.  | |
![]()  | 
function sbAt(at: int = -2): pointer; | 
| 
 Returns pointer on internal bytes 
 Parameters
 Returnspointer to offset in subbuffer  | |
![]()  | 
function sbLeft(): int; | 
![]()  | 
procedure BeforeDestruction(); override; | 
![]()  | 
procedure moveBitOfs(delta: int); | 
| 
 Moves bit position.  | |
![]()  | 
procedure resetOutfillBuf(); | 
| 
 Reset outfill buffer/offset.  | |
![]()  | 
procedure restart(); | 
| 
 Cleans up the reader/parser before new file/stream.  | |
![]()  | 
procedure setOutfillBuf(buf: pointer); | 
| 
 Set outfill buffer.  | |
![]()  | 
procedure skipBytes(numBytes: unsigned); | 
| 
 Skips given number of bytes. Parameters
  | |
![]()  | 
procedure skipToByte(); | 
| 
 Skips all bits till next byte, making sure next bit-read will start from byte boundary.  | |
![]()  | 
procedure doRestart(); virtual; | 
| 
 Cleans up the reader.  | |
![]()  | 
procedure readSubBuf(reqSize: int = -1; append: bool = false); virtual; abstract; | 
| 
 Fills subBuf with new portion of data. subBufSize is set to size of data addressed by subBuf. subBufOfs is set to zero.  | |
![]()  | 
procedure sbAlloc(sz: int; append: bool); | 
![]()  | 
procedure sbAssign(v: pointer; sz: int); | 
![]()  | 
procedure sbIncrease(delta: int); | 
![]()  | 
property bitOfs: int64 read f_bitOfs; | 
| 
 Current offset in bits from beginning of file/stream.  | |
![]()  | 
property bytesLeft: int read sbLeft; | 
![]()  | 
property isEOF: bool read getIsEOF; | 
| 
 True if end of stream/file is reached, False otherwise.  | |
![]()  | 
property outfill: bool read f_outfill write setOutfill; | 
| 
 When outfill is true, all reading/skipping will fill the outfill buffer as well.  | |
![]()  | 
property outfillOfs: int read f_outfillOfs; | 
| 
 Offset in outfill buffer  | |
(c) 2012 Lake of Soft