Public Member Functions | Private Attributes | List of all members
rosbag::BZ2Stream Class Reference

#include <stream.h>

Inheritance diagram for rosbag::BZ2Stream:
Inheritance graph
[legend]

Public Member Functions

 BZ2Stream (ChunkedFile *file)
 
void decompress (uint8_t *dest, unsigned int dest_len, uint8_t *source, unsigned int source_len)
 
CompressionType getCompressionType () const
 
void read (void *ptr, size_t size)
 
void startRead ()
 
void startWrite ()
 
void stopRead ()
 
void stopWrite ()
 
void write (void *ptr, size_t size)
 
- Public Member Functions inherited from rosbag::Stream
 Stream (ChunkedFile *file)
 
virtual ~Stream ()
 

Private Attributes

int block_size_100k_
 compression block size (1-9; 9 default). 9 is best compression, most memory More...
 
int bzerror_
 last error from bzlib More...
 
BZFILE * bzfile_
 bzlib compressed file stream More...
 
int verbosity_
 level of debugging output (0-4; 0 default). 0 is silent, 4 is max verbose debugging output More...
 
int work_factor_
 compression behavior for worst case, highly repetitive data (0-250; 30 default) More...
 

Additional Inherited Members

- Protected Member Functions inherited from rosbag::Stream
void advanceOffset (uint64_t nbytes)
 
void clearUnused ()
 
uint64_t getCompressedIn ()
 
FILE * getFilePointer ()
 
char * getUnused ()
 
int getUnusedLength ()
 
void setCompressedIn (uint64_t nbytes)
 
void setUnused (char *unused)
 
void setUnusedLength (int nUnused)
 
- Protected Attributes inherited from rosbag::Stream
ChunkedFilefile_
 

Detailed Description

BZ2Stream uses libbzip2 (http://www.bzip.org) for reading/writing compressed data in the BZ2 format.

Definition at line 139 of file stream.h.

Constructor & Destructor Documentation

rosbag::BZ2Stream::BZ2Stream ( ChunkedFile file)

Definition at line 49 of file bz2_stream.cpp.

Member Function Documentation

void rosbag::BZ2Stream::decompress ( uint8_t *  dest,
unsigned int  dest_len,
uint8_t *  source,
unsigned int  source_len 
)
virtual

Implements rosbag::Stream.

Definition at line 163 of file bz2_stream.cpp.

CompressionType rosbag::BZ2Stream::getCompressionType ( ) const
virtual

Implements rosbag::Stream.

Definition at line 58 of file bz2_stream.cpp.

void rosbag::BZ2Stream::read ( void *  ptr,
size_t  size 
)
virtual

Implements rosbag::Stream.

Definition at line 121 of file bz2_stream.cpp.

void rosbag::BZ2Stream::startRead ( )
virtual

Reimplemented from rosbag::Stream.

Definition at line 107 of file bz2_stream.cpp.

void rosbag::BZ2Stream::startWrite ( )
virtual

Reimplemented from rosbag::Stream.

Definition at line 62 of file bz2_stream.cpp.

void rosbag::BZ2Stream::stopRead ( )
virtual

Reimplemented from rosbag::Stream.

Definition at line 151 of file bz2_stream.cpp.

void rosbag::BZ2Stream::stopWrite ( )
virtual

Reimplemented from rosbag::Stream.

Definition at line 90 of file bz2_stream.cpp.

void rosbag::BZ2Stream::write ( void *  ptr,
size_t  size 
)
virtual

Implements rosbag::Stream.

Definition at line 76 of file bz2_stream.cpp.

Member Data Documentation

int rosbag::BZ2Stream::block_size_100k_
private

compression block size (1-9; 9 default). 9 is best compression, most memory

Definition at line 158 of file stream.h.

int rosbag::BZ2Stream::bzerror_
private

last error from bzlib

Definition at line 162 of file stream.h.

BZFILE* rosbag::BZ2Stream::bzfile_
private

bzlib compressed file stream

Definition at line 161 of file stream.h.

int rosbag::BZ2Stream::verbosity_
private

level of debugging output (0-4; 0 default). 0 is silent, 4 is max verbose debugging output

Definition at line 157 of file stream.h.

int rosbag::BZ2Stream::work_factor_
private

compression behavior for worst case, highly repetitive data (0-250; 30 default)

Definition at line 159 of file stream.h.


The documentation for this class was generated from the following files:


rosbag_storage
Author(s): Dirk Thomas
autogenerated on Mon Nov 2 2020 03:52:19