CMS 3D CMS Logo

ThreadQueue.h
Go to the documentation of this file.
1 #ifndef FWCore_MessageService_ThreadQueue_h
2 #define FWCore_MessageService_ThreadQueue_h
3 // -*- C++ -*-
4 //
5 // Package: MessageService
6 // Class : ThreadQueue
7 //
16 //
17 // Original Author: mf and cdj
18 // Created: Fri Aug 7 10:19:58 CDT 2009
19 //
20 
23 
24 
25 
26 
27 namespace edm {
28 namespace service {
29 
31 {
32 
33  public:
34  ThreadQueue();
35  virtual ~ThreadQueue();
36 
37  // ---------- const member functions ---------------------
38 
39  // ---------- static member functions --------------------
40 
41  // ---------- member functions ---------------------------
42 
43  // --- obtain a message from the queue:
44  void consume( MessageLoggerQ::OpCode & opcode, void * & operand );
45 
46  // --- place a message onto the queue:
47  void produce( MessageLoggerQ::OpCode opcode, void * operand );
48 
49 
50  private:
51  ThreadQueue(const ThreadQueue&); // stop default
52 
53  const ThreadQueue& operator=(const ThreadQueue&); // stop default
54 
55  // ---------- member data --------------------------------
56 
57  // --- buffer parameters: (were private but needed by MainTrhreadMLscribe
58  static const int buf_depth = 500;
59  static const int buf_size = sizeof(MessageLoggerQ::OpCode)
60  + sizeof(void *);
62 
63 };
64 
65 } // end namespace service
66 } // end namespace edm
67 
68 #endif
static const int buf_depth
Definition: ThreadQueue.h:58
void consume(MessageLoggerQ::OpCode &opcode, void *&operand)
Definition: ThreadQueue.cc:35
HLT enums.
void produce(MessageLoggerQ::OpCode opcode, void *operand)
Definition: ThreadQueue.cc:23
static const int buf_size
Definition: ThreadQueue.h:59
SingleConsumerQ m_buf
Definition: ThreadQueue.h:61
const ThreadQueue & operator=(const ThreadQueue &)