![]() |
CernVM-FS
2.12.0
|
Classes | |
class | Compressor |
class | ZlibCompressor |
class | EchoCompressor |
Enumerations | |
enum | StreamStates { kStreamDataError = 0, kStreamIOError, kStreamContinue, kStreamEnd } |
enum | Algorithms { kZlibDefault = 0, kNoCompression } |
Functions | |
Algorithms | ParseCompressionAlgorithm (const std::string &algorithm_option) |
std::string | AlgorithmName (const zlib::Algorithms alg) |
void | CompressInit (z_stream *strm) |
void | DecompressInit (z_stream *strm) |
void | CompressFini (z_stream *strm) |
void | DecompressFini (z_stream *strm) |
StreamStates | CompressZStream2Null (const void *buf, const int64_t size, const bool eof, z_stream *strm, shash::ContextPtr *hash_context) |
StreamStates | DecompressZStream2Sink (const void *buf, const int64_t size, z_stream *strm, cvmfs::Sink *sink) |
StreamStates | DecompressZStream2File (const void *buf, const int64_t size, z_stream *strm, FILE *f) |
bool | CompressPath2Path (const string &src, const string &dest) |
bool | CompressPath2Path (const string &src, const string &dest, shash::Any *compressed_hash) |
bool | DecompressPath2Path (const string &src, const string &dest) |
bool | CompressFile2Null (FILE *fsrc, shash::Any *compressed_hash) |
bool | CompressFd2Null (int fd_src, shash::Any *compressed_hash, uint64_t *processed_bytes) |
bool | CompressPath2Null (const string &src, shash::Any *compressed_hash) |
bool | CompressFile2File (FILE *fsrc, FILE *fdest) |
bool | CompressPath2File (const string &src, FILE *fdest, shash::Any *compressed_hash) |
bool | CompressFile2File (FILE *fsrc, FILE *fdest, shash::Any *compressed_hash) |
bool | DecompressFile2File (FILE *fsrc, FILE *fdest) |
bool | DecompressPath2File (const string &src, FILE *fdest) |
bool | CompressMem2File (const unsigned char *buf, const size_t size, FILE *fdest, shash::Any *compressed_hash) |
bool | CompressMem2Mem (const void *buf, const int64_t size, void **out_buf, uint64_t *out_size) |
bool | DecompressMem2Mem (const void *buf, const int64_t size, void **out_buf, uint64_t *out_size) |
bool | CompressPath2Path (const std::string &src, const std::string &dest) |
bool | CompressPath2Path (const std::string &src, const std::string &dest, shash::Any *compressed_hash) |
bool | DecompressPath2Path (const std::string &src, const std::string &dest) |
bool | CompressPath2Null (const std::string &src, shash::Any *compressed_hash) |
bool | CompressPath2File (const std::string &src, FILE *fdest, shash::Any *compressed_hash) |
bool | DecompressPath2File (const std::string &src, FILE *fdest) |
Variables | |
const unsigned | kBufferSize = 32768 |
const unsigned | kZChunk = 16384 |
enum zlib::Algorithms |
Enumerator | |
---|---|
kZlibDefault | |
kNoCompression |
Definition at line 44 of file compression.h.
enum zlib::StreamStates |
Enumerator | |
---|---|
kStreamDataError | |
kStreamIOError | |
kStreamContinue | |
kStreamEnd |
Definition at line 36 of file compression.h.
std::string zlib::AlgorithmName | ( | const zlib::Algorithms | alg | ) |
Definition at line 158 of file compression.cc.
Referenced by CompressionMagicXattr::FinalizeValue(), and swissknife::CommandGraft::Publish().
bool zlib::CompressFd2Null | ( | int | fd_src, |
shash::Any * | compressed_hash, | ||
uint64_t * | processed_bytes | ||
) |
Definition at line 453 of file compression.cc.
Referenced by MainCheck().
bool zlib::CompressFile2File | ( | FILE * | fsrc, |
FILE * | fdest | ||
) |
Definition at line 525 of file compression.cc.
Referenced by CompressPath2File(), and CompressPath2Path().
bool zlib::CompressFile2File | ( | FILE * | fsrc, |
FILE * | fdest, | ||
shash::Any * | compressed_hash | ||
) |
bool zlib::CompressFile2Null | ( | FILE * | fsrc, |
shash::Any * | compressed_hash | ||
) |
Definition at line 401 of file compression.cc.
Referenced by CompressPath2Null().
void zlib::CompressFini | ( | z_stream * | strm | ) |
Definition at line 196 of file compression.cc.
Referenced by CacheManager::ChecksumFd(), CompressFd2Null(), CompressFile2File(), CompressFile2Null(), CompressMem2File(), and CompressMem2Mem().
void zlib::CompressInit | ( | z_stream * | strm | ) |
Definition at line 174 of file compression.cc.
Referenced by CacheManager::ChecksumFd(), CompressFd2Null(), CompressFile2File(), CompressFile2Null(), CompressMem2File(), and CompressMem2Mem().
bool zlib::CompressMem2File | ( | const unsigned char * | buf, |
const size_t | size, | ||
FILE * | fdest, | ||
shash::Any * | compressed_hash | ||
) |
Definition at line 678 of file compression.cc.
Referenced by swissknife::StoreBuffer().
bool zlib::CompressMem2Mem | ( | const void * | buf, |
const int64_t | size, | ||
void ** | out_buf, | ||
uint64_t * | out_size | ||
) |
User of this function has to free out_buf.
Definition at line 739 of file compression.cc.
Referenced by catalog::VirtualCatalog::CreateNestedCatalogMarker(), and catalog::CatalogBalancer< CatalogMgrT >::MakeEmptyDirectoryEntryBase().
bool zlib::CompressPath2File | ( | const std::string & | src, |
FILE * | fdest, | ||
shash::Any * | compressed_hash | ||
) |
bool zlib::CompressPath2File | ( | const string & | src, |
FILE * | fdest, | ||
shash::Any * | compressed_hash | ||
) |
bool zlib::CompressPath2Null | ( | const std::string & | src, |
shash::Any * | compressed_hash | ||
) |
bool zlib::CompressPath2Null | ( | const string & | src, |
shash::Any * | compressed_hash | ||
) |
Definition at line 515 of file compression.cc.
Referenced by catalog::WritableCatalogManager::SnapshotCatalogsSerialized().
bool zlib::CompressPath2Path | ( | const std::string & | src, |
const std::string & | dest | ||
) |
bool zlib::CompressPath2Path | ( | const std::string & | src, |
const std::string & | dest, | ||
shash::Any * | compressed_hash | ||
) |
bool zlib::CompressPath2Path | ( | const string & | src, |
const string & | dest | ||
) |
Definition at line 318 of file compression.cc.
Referenced by catalog::WritableCatalogManager::CreateRepository().
bool zlib::CompressPath2Path | ( | const string & | src, |
const string & | dest, | ||
shash::Any * | compressed_hash | ||
) |
StreamStates zlib::CompressZStream2Null | ( | const void * | buf, |
const int64_t | size, | ||
const bool | eof, | ||
z_stream * | strm, | ||
shash::ContextPtr * | hash_context | ||
) |
Definition at line 206 of file compression.cc.
Referenced by CacheManager::ChecksumFd().
bool zlib::DecompressFile2File | ( | FILE * | fsrc, |
FILE * | fdest | ||
) |
Definition at line 640 of file compression.cc.
Referenced by DecompressPath2File(), and DecompressPath2Path().
void zlib::DecompressFini | ( | z_stream * | strm | ) |
Definition at line 201 of file compression.cc.
Referenced by DecompressFile2File(), DecompressMem2Mem(), and download::DownloadManager::VerifyAndFinalize().
void zlib::DecompressInit | ( | z_stream * | strm | ) |
Definition at line 185 of file compression.cc.
Referenced by DecompressFile2File(), DecompressMem2Mem(), download::DownloadManager::InitializeRequest(), and download::DownloadManager::VerifyAndFinalize().
bool zlib::DecompressMem2Mem | ( | const void * | buf, |
const int64_t | size, | ||
void ** | out_buf, | ||
uint64_t * | out_size | ||
) |
User of this function has to free out_buf.
Definition at line 797 of file compression.cc.
bool zlib::DecompressPath2File | ( | const std::string & | src, |
FILE * | fdest | ||
) |
bool zlib::DecompressPath2File | ( | const string & | src, |
FILE * | fdest | ||
) |
Definition at line 667 of file compression.cc.
Referenced by LocalObjectFetcher< CatalogT, HistoryT, ReflogT >::Fetch(), and swissknife::Store().
bool zlib::DecompressPath2Path | ( | const std::string & | src, |
const std::string & | dest | ||
) |
bool zlib::DecompressPath2Path | ( | const string & | src, |
const string & | dest | ||
) |
Definition at line 381 of file compression.cc.
Referenced by swissknife::CommandCheck::DecompressPiece(), swissknife::CommandPull::Main(), and swissknife::CommandPull::Pull().
StreamStates zlib::DecompressZStream2File | ( | const void * | buf, |
const int64_t | size, | ||
z_stream * | strm, | ||
FILE * | f | ||
) |
Definition at line 275 of file compression.cc.
Referenced by DecompressFile2File().
StreamStates zlib::DecompressZStream2Sink | ( | const void * | buf, |
const int64_t | size, | ||
z_stream * | strm, | ||
cvmfs::Sink * | sink | ||
) |
Definition at line 234 of file compression.cc.
Referenced by download::CallbackCurlData().
Algorithms zlib::ParseCompressionAlgorithm | ( | const std::string & | algorithm_option | ) |
Aborts if string doesn't match any of the algorithms.
Definition at line 148 of file compression.cc.
Referenced by publish::SyncItem::CheckGraft(), swissknife::CommandGraft::Main(), swissknife::Ingest::Main(), swissknife::CommandSync::Main(), and publish::SettingsTransaction::SetCompressionAlgorithm().
const unsigned zlib::kBufferSize = 32768 |
Definition at line 143 of file compression.cc.
Referenced by anonymous_namespace{logging.cc}::LogBuffer::Append(), DecompressFile2File(), SqliteMemoryManager::LookasideBufferArena::GetBuffer(), anonymous_namespace{logging.cc}::LogBuffer::GetBuffer(), and SqliteMemoryManager::LookasideBufferArena::PutBuffer().
const unsigned zlib::kZChunk = 16384 |
Definition at line 34 of file compression.h.
Referenced by swissknife::CommandGraft::ChecksumFdWithChunks(), CompressFd2Null(), CompressFile2File(), CompressFile2Null(), CompressMem2File(), CompressMem2Mem(), CompressZStream2Null(), DecompressMem2Mem(), DecompressZStream2File(), and DecompressZStream2Sink().