#include <XrdThrottleManager.hh>
Definition at line 299 of file XrdThrottleManager.hh.
◆ ~XrdThrottleTimer()
| XrdThrottleTimer::~XrdThrottleTimer |
( |
| ) |
|
|
inline |
◆ XrdThrottleTimer() [1/2]
| XrdThrottleTimer::XrdThrottleTimer |
( |
| ) |
|
|
inlineprotected |
Definition at line 315 of file XrdThrottleManager.hh.
315 :
316 m_start_time(std::chrono::steady_clock::time_point::min())
317{}
◆ XrdThrottleTimer() [2/2]
Definition at line 319 of file XrdThrottleManager.hh.
319 :
320 m_owner(uid),
321 m_timer_list_entry(XrdThrottleManager::GetTimerListHash()),
322 m_manager(manager),
323 m_start_time(std::chrono::steady_clock::now())
324{
325 if (!m_manager) {
326 return;
327 }
328 auto &timerList = m_manager->m_timer_list[m_timer_list_entry];
329 std::lock_guard<std::mutex> lock(timerList.m_mutex);
330 if (timerList.m_first == nullptr) {
331 timerList.m_first = this;
332 } else {
333 m_prev = timerList.m_last;
334 m_prev->m_next = this;
335 }
336 timerList.m_last = this;
337}
References XrdThrottleManager.
◆ Reset()
| std::chrono::steady_clock::duration XrdThrottleTimer::Reset |
( |
| ) |
|
|
inlineprotected |
Definition at line 339 of file XrdThrottleManager.hh.
339 {
340 auto now = std::chrono::steady_clock::now();
341 auto last_start = m_start_time.exchange(now);
342 return now - last_start;
343}
◆ XrdThrottleManager
The documentation for this class was generated from the following file: