MonitorPolicy Class Reference

#include <policies.h>

List of all members.

Public Member Functions

 MonitorPolicy ()
chtype getDataType () const
chtype getDbrDataType () const
CAFENUM::DBR_TYPE getCafeDbrType () const
unsigned int getNelem () const
unsigned int getMask () const
bool maskHasDBE_PROPERTY () const
bool maskHasDBE_VALUE () const
bool maskHasDBE_LOG () const
bool maskHasDBE_ALARM () const
pCallback getHandler () const
void * getUserArgs () const
unsigned int getUserArgsAsInt () const
evid getEventID () const
unsigned int getMonitorID () const
int getStatus () const
unsigned int getID () const
void setMask (unsigned int m)
void setPyHandler ()
void setPyHandlerData ()
void setDefaultHandler ()
void setHandler (pCallback h)
void setNelem (unsigned int n)
void setDataType (chtype dt)
void setCafeDbrType (CAFENUM::DBR_TYPE cdt)
void setUserArgs (void *u)
void setStatus (int s)
void print ()

Private Member Functions

void setEventID (evid e)

Static Private Member Functions

static void callbackHandlerMonitor (struct event_handler_args args)
 Callback function for monitor method is invoked with a pointer to the retrieved value.
static void PyCallbackHandlerMonitorData (struct event_handler_args args)
 Callback function for monitor method is invoked with a pointer to the retrieved value; also fires a user supplied Python callback.
static void PyCallbackHandlerMonitor (struct event_handler_args args)
 Callback function for monitor method is invoked with a pointer to the retrieved value; also fires a user supplied Python callback.

Private Attributes

chtype dataType
chtype dbrDataType
CAFENUM::DBR_TYPE cafeDbrType
unsigned int nelem
unsigned int mask
pCallback handler
void * userArgs
evid eventID
int status
unsigned int id

Static Private Attributes

static unsigned int idNext = 0xfff

Friends

class Conduit
class Connect

Detailed Description

Defines policy to start a monitor on a channel upon first connection. Note that CAFE will not start a monitor on a channel if it is not connected as the datatype in such cases is unknown.
The monitor is rather placed in a monitor_in_waiting pseudo-queue and only started upon connection


Constructor & Destructor Documentation

MonitorPolicy::MonitorPolicy (  )  [inline]

References idNext.


Member Function Documentation

void MonitorPolicy::callbackHandlerMonitor ( struct event_handler_args  args  )  [static, private]

Callback function for monitor method is invoked with a pointer to the retrieved value.

Parameters:
args input: event handler arguments

References __METHOD__, cafeMutex, cs, long, and MUTEX.

Referenced by setDefaultHandler().

CAFENUM::DBR_TYPE MonitorPolicy::getCafeDbrType ( void   )  const [inline]

References cafeDbrType.

chtype MonitorPolicy::getDataType (  )  const [inline]

References dataType.

Referenced by Connect::monitorStart().

chtype MonitorPolicy::getDbrDataType (  )  const [inline]

References dbrDataType.

Referenced by Conduit::monitorStart().

evid MonitorPolicy::getEventID (  )  const [inline]

References eventID.

Referenced by Connect::monitorStart().

pCallback MonitorPolicy::getHandler (  )  const [inline]

References handler.

Referenced by Conduit::monitorStart().

unsigned int MonitorPolicy::getID (  )  const [inline]

References id.

Referenced by Connect::monitorStart().

unsigned int MonitorPolicy::getMask (  )  const [inline]

References mask.

Referenced by Conduit::monitorStart().

unsigned int MonitorPolicy::getMonitorID (  )  const [inline]

References id.

Referenced by Connect::monitorStop().

unsigned int MonitorPolicy::getNelem (  )  const [inline]

References nelem.

Referenced by Connect::monitorStart(), and Conduit::monitorStart().

int MonitorPolicy::getStatus ( void   )  const [inline]

References status.

void* MonitorPolicy::getUserArgs (  )  const [inline]

References userArgs.

Referenced by Connect::monitorStart(), and Conduit::monitorStart().

unsigned int MonitorPolicy::getUserArgsAsInt (  )  const [inline]

References long, and userArgs.

bool MonitorPolicy::maskHasDBE_ALARM (  )  const [inline]

References mask.

bool MonitorPolicy::maskHasDBE_LOG (  )  const [inline]

References mask.

bool MonitorPolicy::maskHasDBE_PROPERTY (  )  const [inline]

References mask.

bool MonitorPolicy::maskHasDBE_VALUE (  )  const [inline]

References mask.

void MonitorPolicy::print (  )  [inline]

References dbrDataType, eventID, and nelem.

void MonitorPolicy::PyCallbackHandlerMonitor ( struct event_handler_args  args  )  [static, private]

Callback function for monitor method is invoked with a pointer to the retrieved value; also fires a user supplied Python callback.

Parameters:
args input: event handler arguments

References __METHOD__, cafeMutex, cs, long, and MUTEX.

Referenced by setPyHandler().

void MonitorPolicy::PyCallbackHandlerMonitorData ( struct event_handler_args  args  )  [static, private]

Callback function for monitor method is invoked with a pointer to the retrieved value; also fires a user supplied Python callback.

Parameters:
args input: event handler arguments

References __METHOD__, cafeMutex, cs, long, and MUTEX.

Referenced by setPyHandlerData().

void MonitorPolicy::setCafeDbrType ( CAFENUM::DBR_TYPE  cdt  )  [inline]
void MonitorPolicy::setDataType ( chtype  dt  )  [inline]
void MonitorPolicy::setDefaultHandler (  )  [inline]
void MonitorPolicy::setEventID ( evid  e  )  [inline, private]

References eventID.

Referenced by Conduit::monitorStart().

void MonitorPolicy::setHandler ( pCallback  h  )  [inline]

References handler.

void MonitorPolicy::setMask ( unsigned int  m  )  [inline]

References mask.

void MonitorPolicy::setNelem ( unsigned int  n  )  [inline]

References nelem.

Referenced by Connect::monitorStart().

void MonitorPolicy::setPyHandler (  )  [inline]
void MonitorPolicy::setPyHandlerData (  )  [inline]
void MonitorPolicy::setStatus ( int  s  )  [inline]

References status.

Referenced by Connect::monitorStart().

void MonitorPolicy::setUserArgs ( void *  u  )  [inline]

References userArgs.

Referenced by Connect::monitorStart().


Friends And Related Function Documentation

friend class Conduit [friend]
friend class Connect [friend]

Member Data Documentation

chtype MonitorPolicy::dataType [private]
chtype MonitorPolicy::dbrDataType [private]
evid MonitorPolicy::eventID [private]

Referenced by getEventID(), print(), and setEventID().

unsigned int MonitorPolicy::id [private]

Referenced by getID(), and getMonitorID().

unsigned int MonitorPolicy::idNext = 0xfff [static, private]
unsigned int MonitorPolicy::mask [private]
unsigned int MonitorPolicy::nelem [private]

Referenced by getNelem(), print(), and setNelem().

Referenced by getStatus(), and setStatus().

void* MonitorPolicy::userArgs [private]

The documentation for this class was generated from the following files:

Generated on 3 May 2017 for CAFE by  doxygen 1.6.1