57    if(!
init(compression_level))
 
 
  135    unsigned char const flg(
 
  150    os << static_cast<unsigned char>(0x1f);  
 
  151    os << static_cast<unsigned char>(0x8b);  
 
  152    os << static_cast<unsigned char>(0x08);  
 
  154    os << static_cast<unsigned char>(0x00);  
 
  155    os << static_cast<unsigned char>(0x00);  
 
  156    os << static_cast<unsigned char>(0x00);  
 
  157    os << static_cast<unsigned char>(0x00);  
 
  158    os << static_cast<unsigned char>(0x00);  
 
  159    os << static_cast<unsigned char>(0x00);  
 
  164        os << static_cast<unsigned char>(0x00);
 
  170        os << static_cast<unsigned char>(0x00);
 
 
  187    os << static_cast<unsigned char>( i        & 0xFF);
 
  188    os << static_cast<unsigned char>((i >>  8) & 0xFF);
 
  189    os << static_cast<unsigned char>((i >> 16) & 0xFF);
 
  190    os << static_cast<unsigned char>((i >> 24) & 0xFF);
 
 
A class to handle stream deflate on the fly.
bool init(FileEntry::CompressionLevel compression_level)
Initialize the zlib library.
uint32_t getCrc32() const
Get the CRC32 of the file.
virtual int sync()
Synchronize the buffer.
virtual int overflow(int c=EOF)
Handle an overflow.
void closeStream()
Closing the stream.
size_t getSize() const
Retrieve the size of the file deflated.
int CompressionLevel
The compression level to be used to save an entry.
std::streambuf * m_outbuf
void setComment(std::string const &comment)
void finish()
Finishes the compression.
virtual int sync() override
Synchronize the buffer.
virtual ~GZIPOutputStreambuf() override
Ensures that the stream gets closed properly.
virtual int overflow(int c=EOF) override
Handle an overflow.
void close()
Close the stream.
GZIPOutputStreambuf(std::streambuf *outbuf, FileEntry::CompressionLevel compression_level)
Initialize a GZIPOutputStreambuf object.
void writeInt(uint32_t i)
void setFilename(std::string const &filename)
Exception used when it is not possible to move forward.
File defining zipios::GZIPOutputStreambuf.
The zipios namespace includes the Zipios library definitions.
Various exceptions used throughout the Zipios library, all based on zipios::Exception.