filesystem Class Reference

Retrieve information about a filesystem. More...

#include <fs.h>

List of all members.

Public Types

typedef uint64 size_type

Public Member Functions

 filesystem ()
 C'tor.

 filesystem (const std::string &a_path)
 C'tor.

void clear (void)
 Clear the filesystem object.

void path (const std::string &a_path)
 Retrieve information about the filesystem on which the given path resides.

const std::string path (void) const
 Return the path from which this filesystem information was obtained.

const size_type blocksize (void) const
 Return the filesystem block size.

const size_type total_blocks (void) const
 Return the filesystem's total number of blocks.

const size_type free_blocks (void) const
 Return the filesystem's number of free blocks.

const size_type used_blocks (void) const
 Return the filesystem's number of used blocks.

const size_type total_inodes (void) const
 Return the filesystem's total number of inodes, if supported by the filesystem, otherwise the result is system-dependent, but usually 0.

const size_type free_inodes (void) const
 Return the filesystem's total number of free inodes, if supported by the filesystem, otherwise the result is system-dependent, but usually 0.

const size_type used_inodes (void) const
 Return the filesystem's number of used inodes.

filesystemoperator= (const filesystem &a_class)
 Copy values from another instance.


Private Attributes

std::string m_path
STATFS m_statfs


Detailed Description

Retrieve information about a filesystem.

Definition at line 311 of file fs.h.


Member Typedef Documentation

typedef uint64 filesystem::size_type
 

Definition at line 313 of file fs.h.

Referenced by blocksize(), free_blocks(), free_inodes(), total_blocks(), total_inodes(), used_blocks(), and used_inodes().


Constructor & Destructor Documentation

filesystem::filesystem  ) 
 

C'tor.

Definition at line 1504 of file fs.cc.

References clear().

Here is the call graph for this function:

filesystem::filesystem const std::string &  a_path  ) 
 

C'tor.

Definition at line 1510 of file fs.cc.

References clear(), and path().

Here is the call graph for this function:


Member Function Documentation

const filesystem::size_type filesystem::blocksize void   )  const
 

Return the filesystem block size.

Definition at line 1544 of file fs.cc.

References m_statfs, estring::size_type, and size_type.

void filesystem::clear void   ) 
 

Clear the filesystem object.

Definition at line 1517 of file fs.cc.

References m_statfs, and TRY_nomem.

Referenced by filesystem().

const filesystem::size_type filesystem::free_blocks void   )  const
 

Return the filesystem's number of free blocks.

Definition at line 1564 of file fs.cc.

References m_statfs, estring::size_type, and size_type.

Referenced by vault_stats_report::assign(), vault_manager::select(), vault_manager::usage(), and used_blocks().

const filesystem::size_type filesystem::free_inodes void   )  const
 

Return the filesystem's total number of free inodes, if supported by the filesystem, otherwise the result is system-dependent, but usually 0.

Definition at line 1598 of file fs.cc.

References m_statfs, estring::size_type, and size_type.

Referenced by vault_stats_report::assign(), vault_manager::usage(), and used_inodes().

filesystem & filesystem::operator= const filesystem a_class  ) 
 

Copy values from another instance.

Definition at line 1618 of file fs.cc.

References m_path, m_statfs, and TRY_nomem.

const std::string filesystem::path void   )  const
 

Return the path from which this filesystem information was obtained.

Definition at line 1538 of file fs.cc.

Referenced by filesystem().

void filesystem::path const std::string &  a_path  ) 
 

Retrieve information about the filesystem on which the given path resides.

Definition at line 1524 of file fs.cc.

References ERROR, m_statfs, reform_path(), STATFS, and TRY_nomem.

Referenced by vault_manager::select(), test_filesystem(), and vault_manager::usage().

Here is the call graph for this function:

const filesystem::size_type filesystem::total_blocks void   )  const
 

Return the filesystem's total number of blocks.

Definition at line 1554 of file fs.cc.

References m_statfs, estring::size_type, and size_type.

Referenced by vault_stats_report::assign(), vault_manager::usage(), and used_blocks().

const filesystem::size_type filesystem::total_inodes void   )  const
 

Return the filesystem's total number of inodes, if supported by the filesystem, otherwise the result is system-dependent, but usually 0.

Definition at line 1586 of file fs.cc.

References m_statfs, estring::size_type, and size_type.

Referenced by vault_stats_report::assign(), vault_manager::usage(), and used_inodes().

const filesystem::size_type filesystem::used_blocks void   )  const
 

Return the filesystem's number of used blocks.

Definition at line 1574 of file fs.cc.

References free_blocks(), estring::size_type, size_type, and total_blocks().

Here is the call graph for this function:

const filesystem::size_type filesystem::used_inodes void   )  const
 

Return the filesystem's number of used inodes.

Definition at line 1608 of file fs.cc.

References free_inodes(), estring::size_type, size_type, and total_inodes().

Here is the call graph for this function:


Member Data Documentation

std::string filesystem::m_path [private]
 

Definition at line 333 of file fs.h.

Referenced by operator=().

struct STATFS filesystem::m_statfs [private]
 

Definition at line 334 of file fs.h.

Referenced by blocksize(), clear(), free_blocks(), free_inodes(), operator=(), path(), total_blocks(), and total_inodes().


The documentation for this class was generated from the following files:
Generated on Mon Jul 12 12:10:34 2004 for rvm by doxygen 1.3.6