LLFIO v2.00
Loading...
Searching...
No Matches
llfio_v2_xxx::algorithm::comparison_summary::_lr Struct Reference
Inheritance diagram for llfio_v2_xxx::algorithm::comparison_summary::_lr:
llfio_v2_xxx::algorithm::traversal_summary

Public Types

enum  difference_type : uint8_t {
  entry , entry_kind , content_metadata , noncontent_metadata ,
  content , none
}
 The kind of difference. More...
 
template<class T >
using map_type = std::unordered_map< T, size_t >
 

Public Member Functions

traversal_summaryoperator+= (const traversal_summary &o)
 Adds another summary to this.
 

Static Public Member Functions

static constexpr stat_t::want default_metadata ()
 The default metadata summarised.
 

Public Attributes

traversal_summary::map_type< difference_typedifferences
 The number of items with the given difference.
 
spinlock _lock
 
size_t stats_failed {0}
 The number of handle stat's which failed.
 
size_t directory_opens_failed {0}
 The number of directories which could not be opened.
 
stat_t::want want {stat_t::want::none}
 The summary items desired.
 
map_type< uint64_t > devs
 The number of items with the given device id.
 
map_type< filesystem::file_type > types
 The number of items with the given type.
 
handle::extent_type size {0}
 The sum of maximum extents. On Windows, is for file content only.
 
handle::extent_type allocated {0}
 The sum of allocated extents. On Windows, is for file content only.
 
handle::extent_type file_blocks {0}
 The sum of file allocated blocks.
 
handle::extent_type directory_blocks {0}
 The sum of directory allocated blocks.
 
size_t max_depth {0}
 The maximum depth of the hierarchy.
 

Member Enumeration Documentation

◆ difference_type

The kind of difference.

Enumerator
entry 

Entry name is here but not there.

entry_kind 

Same entry name has different kind e.g. file vs directory.

content_metadata 

Maximum extent or modified timestamp metadata is different.

noncontent_metadata 

Non-content metadata (perms, non-modified timestamps etc) is different.

content 

The content is different (if contents comparison enabled)

none 

There is no difference.

42 {
43 entry, //!< Entry name is here but not there
44 entry_kind, //!< Same entry name has different kind e.g. file vs directory
45 content_metadata, //!< Maximum extent or modified timestamp metadata is different
46 noncontent_metadata, //!< Non-content metadata (perms, non-modified timestamps etc) is different
47 content, //!< The content is different (if contents comparison enabled)
48 none, //!< There is no difference
49 };
@ entry
Entry name is here but not there.
Definition difference.hpp:43
@ content_metadata
Maximum extent or modified timestamp metadata is different.
Definition difference.hpp:45
@ none
There is no difference.
Definition difference.hpp:48
@ entry_kind
Same entry name has different kind e.g. file vs directory.
Definition difference.hpp:44
@ content
The content is different (if contents comparison enabled)
Definition difference.hpp:47
@ noncontent_metadata
Non-content metadata (perms, non-modified timestamps etc) is different.
Definition difference.hpp:46

Member Function Documentation

◆ default_metadata()

static constexpr stat_t::want llfio_v2_xxx::algorithm::traversal_summary::default_metadata ( )
inlinestaticconstexprinherited

The default metadata summarised.

46 {
47 return stat_t::want::dev | stat_t::want::type | stat_t::want::size | stat_t::want::allocated | stat_t::want::blocks;
48 }

◆ operator+=()

traversal_summary & llfio_v2_xxx::algorithm::traversal_summary::operator+= ( const traversal_summary o)
inlineinherited

Adds another summary to this.

124 {
125 lock_guard<spinlock> g(_lock);
126 directory_opens_failed += o.directory_opens_failed;
127 for(auto &i : o.devs)
128 {
129 devs[i.first] += i.second;
130 }
131 for(auto &i : o.types)
132 {
133 types[i.first] += i.second;
134 }
135 size += o.size;
136 allocated += o.allocated;
137 file_blocks += o.file_blocks;
138 directory_blocks += o.directory_blocks;
139 max_depth = std::max(max_depth, o.max_depth);
140 return *this;
141 }
handle::extent_type file_blocks
The sum of file allocated blocks.
Definition summarize.hpp:59
map_type< filesystem::file_type > types
The number of items with the given type.
Definition summarize.hpp:56
size_t directory_opens_failed
The number of directories which could not be opened.
Definition summarize.hpp:52
handle::extent_type directory_blocks
The sum of directory allocated blocks.
Definition summarize.hpp:60
map_type< uint64_t > devs
The number of items with the given device id.
Definition summarize.hpp:55
handle::extent_type size
The sum of maximum extents. On Windows, is for file content only.
Definition summarize.hpp:57
size_t max_depth
The maximum depth of the hierarchy.
Definition summarize.hpp:61
handle::extent_type allocated
The sum of allocated extents. On Windows, is for file content only.
Definition summarize.hpp:58

Member Data Documentation

◆ allocated

handle::extent_type llfio_v2_xxx::algorithm::traversal_summary::allocated {0}
inherited

The sum of allocated extents. On Windows, is for file content only.

58{0}; //!< The sum of allocated extents. On Windows, is for file content only.

◆ directory_blocks

handle::extent_type llfio_v2_xxx::algorithm::traversal_summary::directory_blocks {0}
inherited

The sum of directory allocated blocks.

60{0}; //!< The sum of directory allocated blocks.

◆ directory_opens_failed

size_t llfio_v2_xxx::algorithm::traversal_summary::directory_opens_failed {0}
inherited

The number of directories which could not be opened.

52{0}; //!< The number of directories which could not be opened.

◆ file_blocks

handle::extent_type llfio_v2_xxx::algorithm::traversal_summary::file_blocks {0}
inherited

The sum of file allocated blocks.

59{0}; //!< The sum of file allocated blocks.

◆ max_depth

size_t llfio_v2_xxx::algorithm::traversal_summary::max_depth {0}
inherited

The maximum depth of the hierarchy.

61{0}; //!< The maximum depth of the hierarchy

◆ size

handle::extent_type llfio_v2_xxx::algorithm::traversal_summary::size {0}
inherited

The sum of maximum extents. On Windows, is for file content only.

57{0}; //!< The sum of maximum extents. On Windows, is for file content only.

◆ stats_failed

size_t llfio_v2_xxx::algorithm::traversal_summary::stats_failed {0}
inherited

The number of handle stat's which failed.

51{0}; //!< The number of handle stat's which failed.

◆ want

stat_t::want llfio_v2_xxx::algorithm::traversal_summary::want {stat_t::want::none}
inherited

The summary items desired.

54{stat_t::want::none}; //!< The summary items desired

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