ALib C++ Library
Library Version: 2402 R1
Documentation generated by doxygen
Loading...
Searching...
No Matches
FInfo::DirectorySums Struct Reference

Description:

Recursively accumulated values for directories.

Definition at line 133 of file finfo.hpp.

#include <finfo.hpp>

Public Field Index:

uint32_t QtyErrsAccess = 0
 Number of access errors in the folder and sub-folders.
 
uint32_t QtyErrsBrokenLink = 0
 Number of broken symbolic links in the directory and its sub-folders.
 
uint32_t QtyStopsOnCircularLinks = 0
 Number of recursion aborts due to detected circular links reach of maximum recursion depth.
 
uint32_t QtyStopsOnMaxDepth = 0
 Number of recursion aborts due to reach of maximum recursion depth.
 
ALIB_WARNINGS_ALLOW_UNSAFE_BUFFER_USAGE uinteger Size = 0
 The cumulated sizes of all files and directories.
 
uint32_t TypeCounters [int(Types::MARKER_TYPES_END)] = {0,0,0,0,0,0,0,0}
 Per-type counters.
 

Public Method Index:

constexpr DirectorySums () noexcept=default
 
constexpr DirectorySumsAdd (const FInfo &finfo) noexcept
 
uint32_t Count () const noexcept
 
uint32_t Count (Types type) const noexcept
 
uint32_t CountDirectories () const noexcept
 
uint32_t CountNonDirectories () const noexcept
 
constexpr bool IsDirType (Types type) const noexcept
 
DirectorySumsoperator+= (const DirectorySums &rhs)
 
DirectorySumsoperator-= (const DirectorySums &rhs)
 

Field Details:

◆ QtyErrsAccess

uint32_t QtyErrsAccess = 0

Number of access errors in the folder and sub-folders.

Definition at line 138 of file finfo.hpp.

◆ QtyErrsBrokenLink

uint32_t QtyErrsBrokenLink = 0

Number of broken symbolic links in the directory and its sub-folders.

Definition at line 139 of file finfo.hpp.

◆ QtyStopsOnCircularLinks

uint32_t QtyStopsOnCircularLinks = 0

Number of recursion aborts due to detected circular links reach of maximum recursion depth.

Definition at line 141 of file finfo.hpp.

◆ QtyStopsOnMaxDepth

uint32_t QtyStopsOnMaxDepth = 0

Number of recursion aborts due to reach of maximum recursion depth.

Definition at line 140 of file finfo.hpp.

◆ Size

The cumulated sizes of all files and directories.

Definition at line 136 of file finfo.hpp.

◆ TypeCounters

uint32_t TypeCounters[int(Types::MARKER_TYPES_END)] = {0,0,0,0,0,0,0,0}

Per-type counters.

Definition at line 137 of file finfo.hpp.

Constructor(s) / Destructor Details::

◆ DirectorySums()

constexpr DirectorySums ( )
constexprdefaultnoexcept

Defaulted default constructor.

Method Details:

◆ Add()

constexpr DirectorySums & Add ( const FInfo & finfo)
inlineconstexprnoexcept

Adds a file/directory to the counters

Parameters
finfoThe entry to add.
Returns
A reference to this

Definition at line 192 of file finfo.hpp.

◆ Count() [1/2]

uint32_t Count ( ) const
inlinenoexcept

Returns the cumulated number of entries (of any type).

Returns
The number of entries counted.

Definition at line 202 of file finfo.hpp.

◆ Count() [2/2]

uint32_t Count ( Types type) const
inlinenoexcept

Returns the number of entries of the given type .

Parameters
typeThe type to get the number of entries for.
Returns
The number of directories or symbolic links to directories.

Definition at line 213 of file finfo.hpp.

◆ CountDirectories()

uint32_t CountDirectories ( ) const
inlinenoexcept

Returns the sum of the number of entries of type Types::DIRECTORY and Types::SYMBOLIC_LINK_DIR

Returns
The number of directories or symbolic links to directories.

Definition at line 224 of file finfo.hpp.

◆ CountNonDirectories()

uint32_t CountNonDirectories ( ) const
inlinenoexcept

Returns the sum of the number of entries which are not of type Types::DIRECTORY and Types::SYMBOLIC_LINK_DIR

Returns
The number of regular files, fifo, sockets, etc.

Definition at line 234 of file finfo.hpp.

◆ IsDirType()

constexpr bool IsDirType ( Types type) const
inlineconstexprnoexcept

Returns true if the given type equals either Types::DIRECTORY or Types::SYMBOLIC_LINK_DIR

Parameters
typereturns false if the given type does not represent a directory and true if type equals Types::DIRECTORY or Types::SYMBOLIC_LINK_DIR
Returns
false if the given type does not represent a directory, true otherwise.

Definition at line 184 of file finfo.hpp.

◆ operator+=()

DirectorySums & operator+= ( const DirectorySums & rhs)
inline

Adds the values in the given summary object to this.

Parameters
rhsThe values to add.
Returns
A reference to this

Definition at line 150 of file finfo.hpp.

◆ operator-=()

DirectorySums & operator-= ( const DirectorySums & rhs)
inline

Subtracts the values in the given summary object from this.

Parameters
rhsThe values to subtract.
Returns
A reference to this

Definition at line 165 of file finfo.hpp.


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