pvDatabaseCPP  4.5.1
pvArrayPlugin.h
Go to the documentation of this file.
1 /* pvArrayPlugin.h */
2 /*
3  * The License for this software can be found in the file LICENSE that is included with the distribution.
4  */
5 
6 #ifndef PVARRAYPLUGIN_H
7 #define PVARRAYPLUGIN_H
8 
9 #include <string>
10 #include <map>
11 #include <pv/lock.h>
12 #include <pv/pvData.h>
13 #include <pv/pvPlugin.h>
14 
15 #include <shareLib.h>
16 
17 namespace epics { namespace pvCopy{
18 
19 class PVArrayPlugin;
21 
22 typedef std::tr1::shared_ptr<PVArrayPlugin> PVArrayPluginPtr;
23 typedef std::tr1::shared_ptr<PVArrayFilter> PVArrayFilterPtr;
24 
25 
32 class epicsShareClass PVArrayPlugin : public PVPlugin
33 {
34 private:
35  PVArrayPlugin();
36 public:
37  POINTER_DEFINITIONS(PVArrayPlugin);
38  virtual ~PVArrayPlugin();
42  static void create();
51  virtual PVFilterPtr create(
52  const std::string & requestValue,
53  const PVCopyPtr & pvCopy,
54  const epics::pvData::PVFieldPtr & master);
55 };
56 
60 class epicsShareClass PVArrayFilter : public PVFilter
61 {
62 private:
63  long start;
64  long increment;
65  long end;
66  epics::pvData::PVScalarArrayPtr masterArray;
67 
68  PVArrayFilter(long start,long increment,long end,const epics::pvData::PVScalarArrayPtr & masterArray);
69 public:
70  POINTER_DEFINITIONS(PVArrayFilter);
71  virtual ~PVArrayFilter();
79  static PVArrayFilterPtr create(const std::string & requestValue,const epics::pvData::PVFieldPtr & master);
88  bool filter(const epics::pvData::PVFieldPtr & pvCopy,const epics::pvData::BitSetPtr & bitSet,bool toCopy);
93  std::string getName();
94 };
95 
96 }}
97 #endif /* PVARRAYPLUGIN_H */
98 
std::tr1::shared_ptr< PVFilter > PVFilterPtr
Definition: pvPlugin.h:29
std::tr1::shared_ptr< PVCopy > PVCopyPtr
Definition: pvPlugin.h:25
A filter that gets a sub array from a PVScalarArray.
Definition: pvArrayPlugin.h:60
std::tr1::shared_ptr< PVArrayFilter > PVArrayFilterPtr
Definition: pvArrayPlugin.h:23
A filter plugin that attaches to a field of a PVStrcture.
Definition: pvPlugin.h:44
std::tr1::shared_ptr< PVArrayPlugin > PVArrayPluginPtr
Definition: pvArrayPlugin.h:20
A Filter that is called when a copy PVStructure is being updated.
Definition: pvPlugin.h:68
A plugin for a filter that gets a sub array from a PVScalarArray.
Definition: pvArrayPlugin.h:32