CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes | Friends
edm::LimitedTaskQueue::Resumer Class Reference

#include <LimitedTaskQueue.h>

Public Member Functions

Resumeroperator= (Resumer &&iOther)
 
Resumeroperator= (Resumer const &iOther)
 
bool resume ()
 
 Resumer ()=default
 
 Resumer (Resumer &&iOther)
 
 Resumer (Resumer const &iOther)
 
 ~Resumer ()
 

Private Member Functions

 Resumer (SerialTaskQueue *iQueue)
 

Private Attributes

SerialTaskQueuem_queue = nullptr
 

Friends

class LimitedTaskQueue
 

Detailed Description

Definition at line 66 of file LimitedTaskQueue.h.

Constructor & Destructor Documentation

◆ Resumer() [1/4]

edm::LimitedTaskQueue::Resumer::Resumer ( )
default

◆ ~Resumer()

edm::LimitedTaskQueue::Resumer::~Resumer ( )
inline

Definition at line 71 of file LimitedTaskQueue.h.

71 { resume(); }

References resume().

◆ Resumer() [2/4]

edm::LimitedTaskQueue::Resumer::Resumer ( Resumer &&  iOther)
inline

Definition at line 73 of file LimitedTaskQueue.h.

73 : m_queue(iOther.m_queue) { iOther.m_queue = nullptr; }

◆ Resumer() [3/4]

edm::LimitedTaskQueue::Resumer::Resumer ( Resumer const &  iOther)
inline

Definition at line 75 of file LimitedTaskQueue.h.

75  : m_queue(iOther.m_queue) {
76  if (m_queue) {
77  m_queue->pause();
78  }
79  }

References m_queue, and edm::SerialTaskQueue::pause().

◆ Resumer() [4/4]

edm::LimitedTaskQueue::Resumer::Resumer ( SerialTaskQueue iQueue)
inlineprivate

Definition at line 104 of file LimitedTaskQueue.h.

104 : m_queue{iQueue} {}

Member Function Documentation

◆ operator=() [1/2]

Resumer& edm::LimitedTaskQueue::Resumer::operator= ( Resumer &&  iOther)
inline

Definition at line 85 of file LimitedTaskQueue.h.

85  {
86  if (m_queue) {
87  m_queue->resume();
88  }
89  m_queue = iOther.m_queue;
90  iOther.m_queue = nullptr;
91  return *this;
92  }

References m_queue, and edm::SerialTaskQueue::resume().

◆ operator=() [2/2]

Resumer& edm::LimitedTaskQueue::Resumer::operator= ( Resumer const &  iOther)
inline

Definition at line 81 of file LimitedTaskQueue.h.

81  {
82  auto t = iOther;
83  return (*this = std::move(t));
84  }

References eostools::move(), and OrderedSet::t.

◆ resume()

bool edm::LimitedTaskQueue::Resumer::resume ( )
inline

Definition at line 94 of file LimitedTaskQueue.h.

94  {
95  if (m_queue) {
96  auto q = m_queue;
97  m_queue = nullptr;
98  return q->resume();
99  }
100  return false;
101  }

References m_queue, and data-class-funcs::q.

Referenced by edm::LuminosityBlockProcessingStatus::resumeGlobalLumiQueue(), and ~Resumer().

Friends And Related Function Documentation

◆ LimitedTaskQueue

friend class LimitedTaskQueue
friend

Definition at line 68 of file LimitedTaskQueue.h.

Member Data Documentation

◆ m_queue

SerialTaskQueue* edm::LimitedTaskQueue::Resumer::m_queue = nullptr
private

Definition at line 105 of file LimitedTaskQueue.h.

Referenced by operator=(), resume(), and Resumer().

edm::SerialTaskQueue::resume
bool resume()
Resumes processing if the queue was paused.
Definition: SerialTaskQueue.cc:35
data-class-funcs.q
q
Definition: data-class-funcs.py:169
OrderedSet.t
t
Definition: OrderedSet.py:90
edm::SerialTaskQueue::pause
bool pause()
Pauses processing of additional tasks from the queue.
Definition: SerialTaskQueue.h:96
edm::LimitedTaskQueue::Resumer::m_queue
SerialTaskQueue * m_queue
Definition: LimitedTaskQueue.h:105
eostools.move
def move(src, dest)
Definition: eostools.py:511
edm::LimitedTaskQueue::Resumer::resume
bool resume()
Definition: LimitedTaskQueue.h:94