xrootd
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
XrdZip::Extra Struct Reference

#include <XrdZipExtra.hh>

Public Types

enum  Ovrflw {
  NONE = 0 , UCMPSIZE = 1 , CPMSIZE = 2 , OFFSET = 4 ,
  NBDISK = 8
}
 

Public Member Functions

 Extra (uint64_t fileSize)
 Constructor from file size.
 
 Extra (Extra *extra, uint64_t offset)
 Constructor from another extra + offset.
 
 Extra ()
 Default constructor.
 
void FromBuffer (const char *&buffer, uint16_t exsize, uint8_t flags)
 Constructor from buffer.
 
void Serialize (buffer_t &buffer)
 Serialize the extra field into a buffer.
 

Static Public Member Functions

static const char * Find (const char *buffer, uint16_t length)
 

Public Attributes

uint16_t dataSize
 
uint64_t uncompressedSize
 
uint64_t compressedSize
 
uint64_t offset
 
uint32_t nbDisk
 
uint16_t totalSize
 

Static Public Attributes

static const uint16_t headerID = 0x0001
 The extra field marker.
 

Member Enumeration Documentation

◆ Ovrflw

Enumerator
NONE 
UCMPSIZE 
CPMSIZE 
OFFSET 
NBDISK 

Constructor & Destructor Documentation

◆ Extra() [1/3]

XrdZip::Extra::Extra ( uint64_t  fileSize)
inline

Constructor from file size.

References compressedSize, dataSize, nbDisk, offset, totalSize, and uncompressedSize.

◆ Extra() [2/3]

XrdZip::Extra::Extra ( Extra extra,
uint64_t  offset 
)
inline

Constructor from another extra + offset.

References compressedSize, dataSize, nbDisk, offset, totalSize, and uncompressedSize.

◆ Extra() [3/3]

XrdZip::Extra::Extra ( )
inline

Default constructor.

Member Function Documentation

◆ Find()

static const char * XrdZip::Extra::Find ( const char *  buffer,
uint16_t  length 
)
inlinestatic

Finds the Zip64 extended information extra field

Returns
: pointer to the buffer holding ZIP64 extra field, nullptr on failure

References headerID.

Referenced by XrdZip::CDFH::ParseExtra(), and XrdZip::LFH::ParseExtra().

◆ FromBuffer()

void XrdZip::Extra::FromBuffer ( const char *&  buffer,
uint16_t  exsize,
uint8_t  flags 
)
inline

◆ Serialize()

void XrdZip::Extra::Serialize ( buffer_t buffer)
inline

Serialize the extra field into a buffer.

References compressedSize, XrdZip::copy_bytes(), dataSize, headerID, offset, totalSize, and uncompressedSize.

Member Data Documentation

◆ compressedSize

uint64_t XrdZip::Extra::compressedSize

Referenced by Extra(), Extra(), FromBuffer(), and Serialize().

◆ dataSize

uint16_t XrdZip::Extra::dataSize

Referenced by Extra(), Extra(), FromBuffer(), and Serialize().

◆ headerID

const uint16_t XrdZip::Extra::headerID = 0x0001
static

The extra field marker.

Referenced by Find(), FromBuffer(), and Serialize().

◆ nbDisk

uint32_t XrdZip::Extra::nbDisk

Referenced by Extra(), Extra(), and FromBuffer().

◆ offset

uint64_t XrdZip::Extra::offset

Referenced by Extra(), Extra(), FromBuffer(), and Serialize().

◆ totalSize

uint16_t XrdZip::Extra::totalSize

Referenced by Extra(), Extra(), and Serialize().

◆ uncompressedSize

uint64_t XrdZip::Extra::uncompressedSize

Referenced by Extra(), Extra(), FromBuffer(), and Serialize().


The documentation for this struct was generated from the following file: