Loading...
Searching...
No Matches
XrdPfc::DirUsage Struct Reference

`#include <XrdPfcDirStateBase.hh>`

Collaboration diagram for XrdPfc::DirUsage:

## Public Member Functions

| DirUsage ()=default
| DirUsage (const DirUsage &a, const DirUsage &b)
| DirUsage (const DirUsage &s)=default
DirUsage & | operator= (const DirUsage &)=default
void | update_from_stats (const DirStats &s)
void | update_last_times (const DirUsage &u)

## Public Attributes

time_t | m_LastCloseTime = 0
time_t | m_LastOpenTime = 0
int | m_NDirectories = 0
int | m_NFiles = 0
int | m_NFilesOpen = 0
long long | m_StBlocks = 0

## Detailed Description

Definition at line 15 of file XrdPfcDirStateBase.hh.

## Constructor & Destructor Documentation

## DirUsage() [1/3]

XrdPfc::DirUsage::DirUsage | ( |  | ) |

default

Referenced by DirUsage(), DirUsage(), operator=(), and update_last_times().

Here is the caller graph for this function:

## DirUsage() [2/3]

XrdPfc::DirUsage::DirUsage | ( | const DirUsage & | s | ) |

default

References DirUsage().

Here is the call graph for this function:

## DirUsage() [3/3]

XrdPfc::DirUsage::DirUsage | ( | const DirUsage & | a,
|  | const DirUsage & | b )

inline

Definition at line 30 of file XrdPfcDirStateBase.hh.

:
m_LastOpenTime (std::max(a.m_LastOpenTime, b.m_LastOpenTime)),
m_LastCloseTime (std::max(a.m_LastCloseTime, b.m_LastCloseTime)),
m_StBlocks (a.m_StBlocks + b.m_StBlocks),
m_NFilesOpen (a.m_NFilesOpen + b.m_NFilesOpen),
m_NFiles (a.m_NFiles + b.m_NFiles),
m_NDirectories (a.m_NDirectories + b.m_NDirectories)
{}
XrdPfc::DirUsage::m_NFilesOpen
int m_NFilesOpen
Definition XrdPfcDirStateBase.hh:20
XrdPfc::DirUsage::m_LastOpenTime
time_t m_LastOpenTime
Definition XrdPfcDirStateBase.hh:17
XrdPfc::DirUsage::m_StBlocks
long long m_StBlocks
Definition XrdPfcDirStateBase.hh:19
XrdPfc::DirUsage::m_NDirectories
int m_NDirectories
Definition XrdPfcDirStateBase.hh:22
XrdPfc::DirUsage::m_NFiles
int m_NFiles
Definition XrdPfcDirStateBase.hh:21
XrdPfc::DirUsage::m_LastCloseTime
time_t m_LastCloseTime
Definition XrdPfcDirStateBase.hh:18

References DirUsage(), m_LastCloseTime, m_LastOpenTime, m_NDirectories, m_NFiles, m_NFilesOpen, and m_StBlocks.

Here is the call graph for this function:

## Member Function Documentation

## operator=()

DirUsage & XrdPfc::DirUsage::operator= | ( | const DirUsage & |  | ) |

default

References DirUsage().

Here is the call graph for this function:

## update_from_stats()

void XrdPfc::DirUsage::update_from_stats | ( | const DirStats & | s | ) |

inline

Definition at line 39 of file XrdPfcDirStateBase.hh.

{
m_StBlocks += s.m_StBlocksAdded - s.m_StBlocksRemoved;
m_NFilesOpen += s.m_NFilesOpened - s.m_NFilesClosed;
m_NFiles += s.m_NFilesCreated - s.m_NFilesRemoved;
m_NDirectories += s.m_NDirectoriesCreated - s.m_NDirectoriesRemoved;
}

References m_NDirectories, XrdPfc::DirStats::m_NDirectoriesCreated, XrdPfc::DirStats::m_NDirectoriesRemoved, m_NFiles, XrdPfc::DirStats::m_NFilesClosed, XrdPfc::DirStats::m_NFilesCreated, m_NFilesOpen, XrdPfc::DirStats::m_NFilesOpened, XrdPfc::DirStats::m_NFilesRemoved, m_StBlocks, XrdPfc::Stats::m_StBlocksAdded, and XrdPfc::DirStats::m_StBlocksRemoved.

## update_last_times()

void XrdPfc::DirUsage::update_last_times | ( | const DirUsage & | u | ) |

inline

Definition at line 47 of file XrdPfcDirStateBase.hh.

{
m_LastOpenTime = std::max(m_LastOpenTime, u.m_LastOpenTime);
m_LastCloseTime = std::max(m_LastCloseTime, u.m_LastCloseTime);
}

References DirUsage(), m_LastCloseTime, and m_LastOpenTime.

Here is the call graph for this function:

## Member Data Documentation

## m_LastCloseTime

time_t XrdPfc::DirUsage::m_LastCloseTime = 0

Definition at line 18 of file XrdPfcDirStateBase.hh.

Referenced by DirUsage(), XrdPfc::ResourceMonitor::process_queues(), and update_last_times().

## m_LastOpenTime

time_t XrdPfc::DirUsage::m_LastOpenTime = 0

Definition at line 17 of file XrdPfcDirStateBase.hh.

Referenced by DirUsage(), XrdPfc::ResourceMonitor::process_queues(), and update_last_times().

## m_NDirectories

int XrdPfc::DirUsage::m_NDirectories = 0

Definition at line 22 of file XrdPfcDirStateBase.hh.

Referenced by DirUsage(), XrdPfc::ResourceMonitor::heart_beat(), XrdPfc::ResourceMonitor::perform_purge_check(), update_from_stats(), XrdPfc::DirState::update_stats_and_usages(), and XrdPfc::DirState::upward_propagate_initial_scan_usages().

## m_NFiles

int XrdPfc::DirUsage::m_NFiles = 0

Definition at line 21 of file XrdPfcDirStateBase.hh.

Referenced by DirUsage(), XrdPfc::ResourceMonitor::scan_dir_and_recurse(), update_from_stats(), XrdPfc::DirState::update_stats_and_usages(), and XrdPfc::DirState::upward_propagate_initial_scan_usages().

## m_NFilesOpen

int XrdPfc::DirUsage::m_NFilesOpen = 0

Definition at line 20 of file XrdPfcDirStateBase.hh.

Referenced by DirUsage(), and update_from_stats().

## m_StBlocks

long long XrdPfc::DirUsage::m_StBlocks = 0

Definition at line 19 of file XrdPfcDirStateBase.hh.

Referenced by DirUsage(), XrdPfc::ResourceMonitor::perform_initial_scan(), XrdPfc::ResourceMonitor::scan_dir_and_recurse(), update_from_stats(), and XrdPfc::DirState::upward_propagate_initial_scan_usages().

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

- XrdPfcDirStateBase.hh