CernVM-FS  2.12.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
swissknife::FileStatsDatabase Class Reference

#include <swissknife_filestats.h>

Inheritance diagram for swissknife::FileStatsDatabase:
Collaboration diagram for swissknife::FileStatsDatabase:

Public Member Functions

bool CreateEmptyDatabase ()
int64_t StoreCatalog (int64_t num_entries, int64_t file_size)
int64_t StoreFile (int64_t catalog_id, int64_t object_id)
int64_t StoreObject (const void *hash, int hash_size, int64_t size)
int64_t StoreChunkedFile (int64_t catalog_id)
int64_t StoreChunk (const void *hash, int hash_size, int64_t size, int64_t file_id)
int64_t StoreSymlink (int64_t length)
void InitStatements ()
void DestroyStatements ()
- Public Member Functions inherited from sqlite::Database< FileStatsDatabase >
bool IsEqualSchema (const float value, const float compare) const
bool BeginTransaction () const
bool CommitTransaction () const
GetProperty (const std::string &key) const
GetPropertyDefault (const std::string &key, const T default_value) const
bool SetProperty (const std::string &key, const T value)
bool HasProperty (const std::string &key) const
sqlite3 * sqlite_db () const
const std::string & filename () const
float schema_version () const
unsigned schema_revision () const
bool read_write () const
unsigned GetModifiedRowCount () const
double GetFreePageRatio () const
void GetMemStatistics (MemStatistics *stats) const
bool Vacuum () const
void PrintSqlError (const std::string &error_msg)
std::string GetLastErrorMsg () const
void TakeFileOwnership ()
void DropFileOwnership ()
bool OwnsFile () const
void EnforceSchema (float version, unsigned revision)

Static Public Attributes

static float kLatestSchema = 1
static unsigned kLatestSchemaRevision = 1
- Static Public Attributes inherited from sqlite::Database< FileStatsDatabase >
static const float kSchemaEpsilon

Protected Member Functions

 FileStatsDatabase (const std::string &filename, const OpenMode open_mode)
- Protected Member Functions inherited from sqlite::Database< FileStatsDatabase >
 Database (const std::string &filename, const OpenMode open_mode)
bool Initialize ()
bool CreatePropertiesTable ()
bool PrepareCommonQueries ()
bool OpenDatabase (const int sqlite_open_flags)
bool Configure ()
bool FileReadAhead ()
void ReadSchemaRevision ()
bool StoreSchemaRevision ()
void set_schema_version (const float ver)
void set_schema_revision (const unsigned rev)

Protected Attributes



class sqlite::Database< FileStatsDatabase >

Additional Inherited Members

- Public Types inherited from sqlite::Database< FileStatsDatabase >
enum  OpenMode
- Static Public Member Functions inherited from sqlite::Database< FileStatsDatabase >
static FileStatsDatabase * Create (const std::string &filename)
static FileStatsDatabase * Open (const std::string &filename, const OpenMode open_mode)

Detailed Description

Definition at line 24 of file swissknife_filestats.h.

Constructor & Destructor Documentation

swissknife::FileStatsDatabase::FileStatsDatabase ( const std::string &  filename,
const OpenMode  open_mode 

Definition at line 51 of file swissknife_filestats.h.

Member Function Documentation

bool swissknife::FileStatsDatabase::CreateEmptyDatabase ( )

Definition at line 211 of file

Here is the call graph for this function:

void swissknife::FileStatsDatabase::DestroyStatements ( )

Definition at line 265 of file

void swissknife::FileStatsDatabase::InitStatements ( )

Definition at line 250 of file

int64_t swissknife::FileStatsDatabase::StoreCatalog ( int64_t  num_entries,
int64_t  file_size 

Definition at line 274 of file

int64_t swissknife::FileStatsDatabase::StoreChunk ( const void *  hash,
int  hash_size,
int64_t  size,
int64_t  file_id 

Definition at line 303 of file

int64_t swissknife::FileStatsDatabase::StoreChunkedFile ( int64_t  catalog_id)

Definition at line 296 of file

int64_t swissknife::FileStatsDatabase::StoreFile ( int64_t  catalog_id,
int64_t  object_id 

Definition at line 283 of file

int64_t swissknife::FileStatsDatabase::StoreObject ( const void *  hash,
int  hash_size,
int64_t  size 

Definition at line 314 of file

int64_t swissknife::FileStatsDatabase::StoreSymlink ( int64_t  length)

Definition at line 329 of file

Friends And Related Function Documentation

friend class sqlite::Database< FileStatsDatabase >

Definition at line 50 of file swissknife_filestats.h.

Member Data Documentation

float swissknife::FileStatsDatabase::kLatestSchema = 1

Definition at line 40 of file swissknife_filestats.h.

unsigned swissknife::FileStatsDatabase::kLatestSchemaRevision = 1

Definition at line 41 of file swissknife_filestats.h.

sqlite::Sql* swissknife::FileStatsDatabase::query_insert_catalog

Definition at line 44 of file swissknife_filestats.h.

sqlite::Sql* swissknife::FileStatsDatabase::query_insert_file

Definition at line 46 of file swissknife_filestats.h.

sqlite::Sql* swissknife::FileStatsDatabase::query_insert_file_object

Definition at line 47 of file swissknife_filestats.h.

sqlite::Sql* swissknife::FileStatsDatabase::query_insert_object

Definition at line 45 of file swissknife_filestats.h.

sqlite::Sql* swissknife::FileStatsDatabase::query_insert_symlink

Definition at line 48 of file swissknife_filestats.h.

sqlite::Sql* swissknife::FileStatsDatabase::query_lookup_object

Definition at line 49 of file swissknife_filestats.h.

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