CMS 3D CMS Logo

Public Member Functions | Private Types | Private Attributes

smproxy::DQMEventMsg Class Reference

#include <DQMEventMsg.h>

List of all members.

Public Member Functions

unsigned char * dataLocation () const
 DQMEventMsg ()
 DQMEventMsg (const DQMEventMsgView &)
const stor::DQMKeydqmKey () const
bool empty () const
bool faulty () const
const stor::QueueIDsgetDQMEventConsumerTags () const
size_t memoryUsed () const
void tagForDQMEventConsumers (const stor::QueueIDs &)
unsigned long totalDataSize () const

Private Types

typedef std::vector< unsigned
char > 
DQMEventMsgBuffer

Private Attributes

boost::shared_ptr
< DQMEventMsgBuffer
buf_
stor::DQMKey dqmKey_
bool faulty_
stor::QueueIDs queueIDs_

Detailed Description

A class for storing an DQMEventMsgView and providing the basic APIs required for SMPS

Author:
mommsen
Revision:
1.2
Date:
2011/03/07 15:41:54

Definition at line 25 of file DQMEventMsg.h.


Member Typedef Documentation

typedef std::vector<unsigned char> smproxy::DQMEventMsg::DQMEventMsgBuffer [private]

Definition at line 74 of file DQMEventMsg.h.


Constructor & Destructor Documentation

smproxy::DQMEventMsg::DQMEventMsg ( )

Definition at line 10 of file DQMEventMsg.cc.

                           :
  faulty_(true)
  {}
smproxy::DQMEventMsg::DQMEventMsg ( const DQMEventMsgView dqmEventMsgView)

Member Function Documentation

unsigned char * smproxy::DQMEventMsg::dataLocation ( ) const

Returns the start adderess of the event message

Definition at line 60 of file DQMEventMsg.cc.

  {
    return &(*buf_)[0];
  }
const stor::DQMKey & smproxy::DQMEventMsg::dqmKey ( ) const

Return the DQM key corresponding to this message

Definition at line 42 of file DQMEventMsg.cc.

References dqmKey_.

  {
    return dqmKey_;
  }
bool smproxy::DQMEventMsg::empty ( void  ) const

Returns true if no event message is managed by *this

Definition at line 66 of file DQMEventMsg.cc.

References buf_.

  {
    return (buf_.get() == 0);
  }
bool smproxy::DQMEventMsg::faulty ( ) const

Returns true if the event message is faulty

Definition at line 72 of file DQMEventMsg.cc.

References faulty_.

  {
    return faulty_;
  }
const stor::QueueIDs & smproxy::DQMEventMsg::getDQMEventConsumerTags ( ) const

Return the QueueIDs for which the DQM event is tagged

Definition at line 36 of file DQMEventMsg.cc.

References queueIDs_.

  {
    return queueIDs_;
  }
size_t smproxy::DQMEventMsg::memoryUsed ( ) const

Returns the total memory occupied by the event message

Definition at line 48 of file DQMEventMsg.cc.

References buf_.

  {
    return sizeof(buf_);
  }
void smproxy::DQMEventMsg::tagForDQMEventConsumers ( const stor::QueueIDs queueIDs)

Tag the DQM event for the passed list of queueIDs

Definition at line 30 of file DQMEventMsg.cc.

References queueIDs_.

  {
    queueIDs_ = queueIDs;
  }
unsigned long smproxy::DQMEventMsg::totalDataSize ( ) const

Returns the size of the event message

Definition at line 54 of file DQMEventMsg.cc.

References buf_.

  {
    return buf_->size();
  }

Member Data Documentation

boost::shared_ptr<DQMEventMsgBuffer> smproxy::DQMEventMsg::buf_ [private]

Definition at line 75 of file DQMEventMsg.h.

Referenced by DQMEventMsg(), empty(), memoryUsed(), and totalDataSize().

Definition at line 79 of file DQMEventMsg.h.

Referenced by DQMEventMsg(), and dqmKey().

Definition at line 76 of file DQMEventMsg.h.

Referenced by faulty().

Definition at line 78 of file DQMEventMsg.h.

Referenced by getDQMEventConsumerTags(), and tagForDQMEventConsumers().