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

#include <directory_entry.h>

Inheritance diagram for catalog::DirectoryEntryBase:
Collaboration diagram for catalog::DirectoryEntryBase:

Classes

struct  Difference
 

Public Types

typedef unsigned int Differences
 

Public Member Functions

 DirectoryEntryBase ()
 
bool IsRegular () const
 
bool IsLink () const
 
bool IsDirectory () const
 
bool IsFifo () const
 
bool IsSocket () const
 
bool IsCharDev () const
 
bool IsBlockDev () const
 
bool IsSpecial () const
 
bool IsExternalFile () const
 
bool IsDirectIo () const
 
bool HasXattrs () const
 
inode_t inode () const
 
uint32_t linkcount () const
 
NameString name () const
 
LinkString symlink () const
 
time_t mtime () const
 
unsigned int mode () const
 
uid_t uid () const
 
gid_t gid () const
 
shash::Any checksum () const
 
const shash::Anychecksum_ptr () const
 
shash::Algorithms hash_algorithm () const
 
uint64_t size () const
 
dev_t rdev () const
 
std::string GetFullPath (const std::string &parent_directory) const
 
void set_inode (const inode_t inode)
 
void set_linkcount (const uint32_t linkcount)
 
void set_symlink (const LinkString &symlink)
 
void set_has_xattrs (const bool has_xattrs)
 
zlib::Algorithms compression_algorithm () const
 
struct stat GetStatStructure () const
 
Differences CompareTo (const DirectoryEntryBase &other) const
 
bool operator== (const DirectoryEntryBase &other) const
 
bool operator!= (const DirectoryEntryBase &other) const
 

Static Public Attributes

static const inode_t kInvalidInode = 0
 

Protected Attributes

inode_t inode_
 
NameString name_
 
unsigned int mode_
 
uid_t uid_
 
gid_t gid_
 
uint64_t size_
 
time_t mtime_
 
LinkString symlink_
 
uint32_t linkcount_
 
bool has_xattrs_
 
shash::Any checksum_
 
bool is_external_file_
 
bool is_direct_io_
 
zlib::Algorithms compression_algorithm_
 

Friends

class CatalogBalancer< MockCatalogManager >
 
class CatalogBalancer< WritableCatalogManager >
 
class publish::SyncItem
 
class publish::SyncItemNative
 
class publish::SyncItemTar
 
class publish::SyncItemDummyDir
 
class publish::SyncItemDummyCatalog
 
class SqlDirentTouch
 
class VirtualCatalog
 

Detailed Description

Wrapper around struct dirent. Only contains file system related meta data for a directory entry. TODO(jblomer): separation to DirectoryEntry not quite clear: this one also contains hash, compression algorithm and external flag

Definition at line 59 of file directory_entry.h.

Member Typedef Documentation

Definition at line 100 of file directory_entry.h.

Constructor & Destructor Documentation

catalog::DirectoryEntryBase::DirectoryEntryBase ( )
inline

Zero-constructed DirectoryEntry objects are unusable as such.

Definition at line 105 of file directory_entry.h.

Member Function Documentation

const shash::Any* catalog::DirectoryEntryBase::checksum_ptr ( ) const
inline

Definition at line 142 of file directory_entry.h.

Referenced by catalog::SqlDirent::CreateDatabaseFlags().

Here is the caller graph for this function:

DirectoryEntryBase::Differences catalog::DirectoryEntryBase::CompareTo ( const DirectoryEntryBase other) const

Definition at line 9 of file directory_entry.cc.

Referenced by catalog::DirectoryEntry::CompareTo(), and operator==().

Here is the call graph for this function:

Here is the caller graph for this function:

zlib::Algorithms catalog::DirectoryEntryBase::compression_algorithm ( ) const
inline
std::string catalog::DirectoryEntryBase::GetFullPath ( const std::string &  parent_directory) const
inline

Definition at line 158 of file directory_entry.h.

Referenced by catalog::WritableCatalogManager::AddChunkedFile(), and catalog::WritableCatalogManager::AddFile().

Here is the call graph for this function:

Here is the caller graph for this function:

struct stat catalog::DirectoryEntryBase::GetStatStructure ( ) const
inline

Converts to a stat struct as required by many Fuse callbacks.

Returns
the struct stat for this DirectoryEntry

Definition at line 184 of file directory_entry.h.

Referenced by cvmfs::cvmfs_getattr(), cvmfs::cvmfs_lookup(), cvmfs::cvmfs_open(), cvmfs::cvmfs_opendir(), LibContext::GetAttr(), and catalog::Catalog::ListingMd5PathStat().

Here is the call graph for this function:

Here is the caller graph for this function:

gid_t catalog::DirectoryEntryBase::gid ( ) const
inline

Definition at line 140 of file directory_entry.h.

Referenced by catalog::CatalogBalancer< CatalogMgrT >::AddCatalogMarker(), LibContext::CvmfsAttrFromDirent(), and GetStatStructure().

Here is the caller graph for this function:

shash::Algorithms catalog::DirectoryEntryBase::hash_algorithm ( ) const
inline
bool catalog::DirectoryEntryBase::IsBlockDev ( ) const
inline

Definition at line 125 of file directory_entry.h.

Referenced by IsSpecial(), rdev(), and size().

Here is the caller graph for this function:

bool catalog::DirectoryEntryBase::IsCharDev ( ) const
inline

Definition at line 124 of file directory_entry.h.

Referenced by IsSpecial(), rdev(), and size().

Here is the caller graph for this function:

bool catalog::DirectoryEntryBase::IsDirectIo ( ) const
inline

Definition at line 130 of file directory_entry.h.

Referenced by catalog::DirectoryEntry::CompareTo(), catalog::SqlDirent::CreateDatabaseFlags(), cvmfs::cvmfs_open(), and DirectIoMagicXattr::FinalizeValue().

Here is the caller graph for this function:

bool catalog::DirectoryEntryBase::IsFifo ( ) const
inline

Definition at line 122 of file directory_entry.h.

Referenced by IsSpecial().

Here is the caller graph for this function:

bool catalog::DirectoryEntryBase::IsSocket ( ) const
inline

Definition at line 123 of file directory_entry.h.

Referenced by IsSpecial().

Here is the caller graph for this function:

bool catalog::DirectoryEntryBase::IsSpecial ( ) const
inline

Definition at line 126 of file directory_entry.h.

Referenced by catalog::DeltaCounters::ApplyDelta(), publish::SyncItemTar::CreateBasicCatalogDirent(), and catalog::SqlDirent::CreateDatabaseFlags().

Here is the call graph for this function:

Here is the caller graph for this function:

unsigned int catalog::DirectoryEntryBase::mode ( ) const
inline

Definition at line 138 of file directory_entry.h.

Referenced by swissknife::CommandCheck::CompareEntries(), CompareTo(), cvmfs::cvmfs_lookup(), LibContext::CvmfsAttrFromDirent(), and cvmfs::GetDirentForInode().

Here is the caller graph for this function:

time_t catalog::DirectoryEntryBase::mtime ( ) const
inline

Definition at line 137 of file directory_entry.h.

Referenced by swissknife::CommandCheck::CompareEntries(), CompareTo(), LibContext::CvmfsAttrFromDirent(), and cvmfs::HasDifferentContent().

Here is the caller graph for this function:

bool catalog::DirectoryEntryBase::operator!= ( const DirectoryEntryBase other) const
inline

Definition at line 207 of file directory_entry.h.

bool catalog::DirectoryEntryBase::operator== ( const DirectoryEntryBase other) const
inline

Definition at line 204 of file directory_entry.h.

Here is the call graph for this function:

dev_t catalog::DirectoryEntryBase::rdev ( ) const
inline

Definition at line 153 of file directory_entry.h.

Referenced by LibContext::CvmfsAttrFromDirent(), and GetStatStructure().

Here is the call graph for this function:

Here is the caller graph for this function:

void catalog::DirectoryEntryBase::set_has_xattrs ( const bool  has_xattrs)
inline

Definition at line 172 of file directory_entry.h.

void catalog::DirectoryEntryBase::set_inode ( const inode_t  inode)
inline

Definition at line 164 of file directory_entry.h.

Referenced by AppendLastEntry(), cvmfs::cvmfs_lookup(), catalog::Catalog::FixTransitionPoint(), cvmfs::GetDirentForInode(), and cvmfs::GetDirentForPath().

Here is the call graph for this function:

Here is the caller graph for this function:

void catalog::DirectoryEntryBase::set_linkcount ( const uint32_t  linkcount)
inline

Definition at line 165 of file directory_entry.h.

Referenced by catalog::WritableCatalogManager::AddDirectory(), catalog::WritableCatalogManager::AddHardlinkGroup(), catalog::WritableCatalogManager::RemoveDirectory(), and SplitHardlink().

Here is the call graph for this function:

Here is the caller graph for this function:

void catalog::DirectoryEntryBase::set_symlink ( const LinkString symlink)
inline

Definition at line 169 of file directory_entry.h.

Referenced by cvmfs::cvmfs_getxattr(), and catalog::AbstractCatalogManager< CatalogT >::LookupPath().

Here is the call graph for this function:

Here is the caller graph for this function:

uid_t catalog::DirectoryEntryBase::uid ( ) const
inline

Definition at line 139 of file directory_entry.h.

Referenced by catalog::CatalogBalancer< CatalogMgrT >::AddCatalogMarker(), LibContext::CvmfsAttrFromDirent(), and GetStatStructure().

Here is the caller graph for this function:

Friends And Related Function Documentation

friend class CatalogBalancer< MockCatalogManager >
friend

Definition at line 61 of file directory_entry.h.

friend class CatalogBalancer< WritableCatalogManager >
friend

Definition at line 63 of file directory_entry.h.

friend class publish::SyncItem
friend

Definition at line 65 of file directory_entry.h.

friend class publish::SyncItemDummyCatalog
friend

Definition at line 69 of file directory_entry.h.

friend class publish::SyncItemDummyDir
friend

Definition at line 68 of file directory_entry.h.

friend class publish::SyncItemNative
friend

Definition at line 66 of file directory_entry.h.

friend class publish::SyncItemTar
friend

Definition at line 67 of file directory_entry.h.

friend class SqlDirentTouch
friend

Definition at line 71 of file directory_entry.h.

friend class VirtualCatalog
friend

Definition at line 73 of file directory_entry.h.

Member Data Documentation

bool catalog::DirectoryEntryBase::has_xattrs_
protected

Definition at line 227 of file directory_entry.h.

Referenced by catalog::SqlLookup::GetDirent(), HasXattrs(), and set_has_xattrs().

bool catalog::DirectoryEntryBase::is_direct_io_
protected

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