Go to the documentation of this file.00001 #ifndef acsexmplCallbacks_h
00002 #define acsexmplCallbacks_h
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030 #include <baciS.h>
00031
00032
00033 #include <ace/SString.h>
00034
00041
00046
00088
00089
00090
00099 class CommonCallback
00100 {
00101 public:
00105 CommonCallback() {}
00106
00107 protected:
00112 ACE_CString prop;
00113
00119 unsigned int m_count;
00120
00121 private:
00125 void operator=(const CommonCallback&);
00126 };
00128
00136 class MyAlarmdouble : public virtual POA_ACS::Alarmdouble,
00137 protected CommonCallback
00138 {
00139 public:
00144 MyAlarmdouble(ACE_CString _prop) { prop = _prop; }
00145
00149 ~MyAlarmdouble() {}
00150
00161 void
00162 alarm_raised (CORBA::Double value,
00163 const ACSErr::Completion &c,
00164 const ACS::CBDescOut &desc);
00165
00176 void
00177 alarm_cleared (CORBA::Double value,
00178 const ACSErr::Completion &c,
00179 const ACS::CBDescOut &desc);
00180
00194 CORBA::Boolean
00195 negotiate (ACS::TimeInterval time_to_transmit, const ACS::CBDescOut &desc)
00196 {
00197 return true;
00198 }
00199
00200 };
00202
00206 class MyCBdouble : public virtual POA_ACS::CBdouble,
00207 protected CommonCallback
00208 {
00209 public:
00214 MyCBdouble(ACE_CString _prop) { prop = _prop; m_count = 0; }
00215
00219 ~MyCBdouble() {}
00220
00232 void
00233 working (CORBA::Double value, const ACSErr::Completion &c, const ACS::CBDescOut &desc);
00234
00246 void
00247 done (CORBA::Double value, const ACSErr::Completion &c, const ACS::CBDescOut &desc);
00248
00262 CORBA::Boolean
00263 negotiate (ACS::TimeInterval time_to_transmit, const ACS::CBDescOut &desc)
00264 {
00265 return true;
00266 }
00267 };
00269
00273 class MyCBvoid: public virtual POA_ACS::CBvoid,
00274 protected CommonCallback
00275 {
00276 public:
00281 MyCBvoid(ACE_CString _prop) { prop = _prop; }
00282
00286 ~MyCBvoid() {}
00287
00299 void
00300 working (const ACSErr::Completion &c, const ACS::CBDescOut &desc);
00301
00312 void
00313 done (const ACSErr::Completion &c, const ACS::CBDescOut &desc);
00314
00329 CORBA::Boolean
00330 negotiate (ACS::TimeInterval time_to_transmit, const ACS::CBDescOut &desc)
00331 {
00332 return true;
00333 }
00334 };
00336
00337 #endif
00338
00339
00340
00341