CernVM-FS  2.9.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
ChunkItem Class Reference

#include <item.h>

Inheritance diagram for ChunkItem:
Collaboration diagram for ChunkItem:

Public Member Functions

 ChunkItem (FileItem *file_item, uint64_t offset)
 
void MakeBulkChunk ()
 
bool IsSolePiece ()
 
bool is_bulk_chunk ()
 
FileItemfile_item ()
 
uint64_t offset ()
 
uint64_t size ()
 
upload::UploadStreamHandleupload_handle ()
 
zlib::CompressorGetCompressor ()
 
void ReleaseCompressor ()
 
shash::ContextPtr hash_ctx ()
 
shash::Anyhash_ptr ()
 
void set_size (uint64_t val)
 
void set_upload_handle (upload::UploadStreamHandle *val)
 

Private Attributes

FileItemfile_item_
 
uint64_t offset_
 
uint64_t size_
 
bool is_bulk_chunk_
 
upload::UploadStreamHandleupload_handle_
 
UniquePtr< zlib::Compressorcompressor_
 
shash::ContextPtr hash_ctx_
 
shash::Any hash_value_
 
unsigned char hash_ctx_buffer_ [shash::kMaxContextSize]
 

Additional Inherited Members

- Private Member Functions inherited from SingleCopy
 SingleCopy ()
 

Detailed Description

A chunk stores the state of compression and hashing contexts as the blocks move through the pipeline. A chunk can be a "bulk chunk" corresponding to the processed data of an entire file, or it can be a partial chunk of a (large) input file.

Definition at line 125 of file item.h.

Constructor & Destructor Documentation

ChunkItem::ChunkItem ( FileItem file_item,
uint64_t  offset 
)

Definition at line 69 of file item.cc.

Here is the call graph for this function:

Member Function Documentation

FileItem* ChunkItem::file_item ( )
inline

Definition at line 135 of file item.h.

Referenced by TaskWrite::OnChunkComplete().

Here is the caller graph for this function:

zlib::Compressor * ChunkItem::GetCompressor ( )

Definition at line 93 of file item.cc.

Referenced by TaskCompress::Process().

Here is the call graph for this function:

Here is the caller graph for this function:

shash::ContextPtr ChunkItem::hash_ctx ( )
inline

Definition at line 145 of file item.h.

Referenced by TaskHash::Process().

Here is the caller graph for this function:

shash::Any* ChunkItem::hash_ptr ( )
inline

Definition at line 146 of file item.h.

Referenced by TaskWrite::OnChunkComplete(), TaskHash::Process(), and TaskWrite::Process().

Here is the caller graph for this function:

bool ChunkItem::is_bulk_chunk ( )
inline

Definition at line 134 of file item.h.

bool ChunkItem::IsSolePiece ( )
inline

Definition at line 130 of file item.h.

Referenced by TaskWrite::Process().

Here is the call graph for this function:

Here is the caller graph for this function:

void ChunkItem::MakeBulkChunk ( )

Definition at line 87 of file item.cc.

Referenced by TaskWrite::Process(), and TaskChunk::Process().

Here is the call graph for this function:

Here is the caller graph for this function:

uint64_t ChunkItem::offset ( )
inline

Definition at line 136 of file item.h.

Referenced by TaskWrite::OnChunkComplete(), and TaskChunk::Process().

Here is the caller graph for this function:

void ChunkItem::ReleaseCompressor ( )

Definition at line 102 of file item.cc.

Referenced by TaskCompress::Process().

Here is the call graph for this function:

Here is the caller graph for this function:

void ChunkItem::set_size ( uint64_t  val)
inline

Definition at line 148 of file item.h.

Referenced by TaskChunk::Process().

Here is the call graph for this function:

Here is the caller graph for this function:

void ChunkItem::set_upload_handle ( upload::UploadStreamHandle val)
inline

Definition at line 149 of file item.h.

Referenced by TaskWrite::Process().

Here is the call graph for this function:

Here is the caller graph for this function:

uint64_t ChunkItem::size ( )
inline

Definition at line 137 of file item.h.

Referenced by TaskWrite::OnChunkComplete().

Here is the caller graph for this function:

upload::UploadStreamHandle* ChunkItem::upload_handle ( )
inline

Definition at line 138 of file item.h.

Referenced by TaskWrite::Process().

Here is the caller graph for this function:

Member Data Documentation

UniquePtr<zlib::Compressor> ChunkItem::compressor_
private

Definition at line 167 of file item.h.

Referenced by GetCompressor(), and ReleaseCompressor().

FileItem* ChunkItem::file_item_
private

Definition at line 155 of file item.h.

Referenced by ChunkItem(), file_item(), GetCompressor(), IsSolePiece(), and MakeBulkChunk().

shash::ContextPtr ChunkItem::hash_ctx_
private

Definition at line 168 of file item.h.

Referenced by ChunkItem(), and hash_ctx().

unsigned char ChunkItem::hash_ctx_buffer_[shash::kMaxContextSize]
private

Definition at line 170 of file item.h.

Referenced by ChunkItem().

shash::Any ChunkItem::hash_value_
private

Definition at line 169 of file item.h.

Referenced by ChunkItem(), hash_ptr(), and MakeBulkChunk().

bool ChunkItem::is_bulk_chunk_
private

Definition at line 162 of file item.h.

Referenced by is_bulk_chunk(), IsSolePiece(), and MakeBulkChunk().

uint64_t ChunkItem::offset_
private

Definition at line 156 of file item.h.

Referenced by IsSolePiece(), and offset().

uint64_t ChunkItem::size_
private

The size of a chunk is not defined before the corresponding stop block has been dispatched.

Definition at line 161 of file item.h.

Referenced by IsSolePiece(), set_size(), and size().

upload::UploadStreamHandle* ChunkItem::upload_handle_
private

Deleted by the uploader.

Definition at line 166 of file item.h.

Referenced by set_upload_handle(), and upload_handle().


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