main addition is array performance example
This commit is contained in:
71
example/src/arrayPerformance/longArrayMonitor.h
Normal file
71
example/src/arrayPerformance/longArrayMonitor.h
Normal file
@@ -0,0 +1,71 @@
|
||||
/* longArrayMonitor.h */
|
||||
/**
|
||||
* Copyright - See the COPYRIGHT that is included with this distribution.
|
||||
* EPICS pvData is distributed subject to a Software License Agreement found
|
||||
* in file LICENSE that is included with this distribution.
|
||||
*/
|
||||
/**
|
||||
* @author mrk
|
||||
* @date 2013.08.09
|
||||
*/
|
||||
#ifndef LONGARRAYMONITOR_H
|
||||
#define LONGARRAYMONITOR_H
|
||||
|
||||
#include <pv/event.h>
|
||||
#include <pv/lock.h>
|
||||
#include <pv/standardPVField.h>
|
||||
#include <pv/timeStamp.h>
|
||||
#include <pv/pvTimeStamp.h>
|
||||
#include <pv/pvAccess.h>
|
||||
|
||||
namespace epics { namespace pvDatabase {
|
||||
|
||||
|
||||
class LongArrayMonitor;
|
||||
typedef std::tr1::shared_ptr<LongArrayMonitor> LongArrayMonitorPtr;
|
||||
|
||||
class LAMChannelRequester;
|
||||
typedef std::tr1::shared_ptr<LAMChannelRequester> LAMChannelRequesterPtr;
|
||||
|
||||
class LAMMonitorRequester;
|
||||
typedef std::tr1::shared_ptr<LAMMonitorRequester> LAMMonitorRequesterPtr;
|
||||
|
||||
class LongArrayMonitor :
|
||||
public std::tr1::enable_shared_from_this<LongArrayMonitor>
|
||||
{
|
||||
public:
|
||||
POINTER_DEFINITIONS(LongArrayMonitor);
|
||||
static LongArrayMonitorPtr create(
|
||||
epics::pvData::String const & providerName,
|
||||
epics::pvData::String const & channelName,
|
||||
bool useQueue = false);
|
||||
~LongArrayMonitor();
|
||||
void start();
|
||||
void stop();
|
||||
void destroy();
|
||||
private:
|
||||
static epics::pvData::Mutex printMutex;
|
||||
bool init(
|
||||
epics::pvData::String const & providerName,
|
||||
epics::pvData::String const & channelName,
|
||||
bool useQueue);
|
||||
LongArrayMonitorPtr getPtrSelf()
|
||||
{
|
||||
return shared_from_this();
|
||||
}
|
||||
LongArrayMonitor();
|
||||
|
||||
LAMChannelRequesterPtr channelRequester;
|
||||
LAMMonitorRequesterPtr monitorRequester;
|
||||
epics::pvAccess::Channel::shared_pointer channel;
|
||||
epics::pvData::Monitor::shared_pointer monitor;
|
||||
epics::pvData::Event event;
|
||||
epics::pvData::Status status;
|
||||
friend class LAMChannelRequester;
|
||||
friend class LAMMonitorRequester;
|
||||
};
|
||||
|
||||
|
||||
}}
|
||||
|
||||
#endif /* LONGARRAYMONITOR_H */
|
||||
Reference in New Issue
Block a user