• Classes
  • Modules
  • Namespaces
  • Files
  • Related Pages
  • File List
  • File Members

baciRWcontImpl_T.h

Go to the documentation of this file.
00001 #ifndef _baciRWcontImpl_T_H_
00002 #define _baciRWcontImpl_T_H_
00003 
00004 /*******************************************************************
00005 * ALMA - Atacama Large Millimiter Array
00006 * (c) European Southern Observatory, 2003 
00007 *
00008 *This library is free software; you can redistribute it and/or
00009 *modify it under the terms of the GNU Lesser General Public
00010 *License as published by the Free Software Foundation; either
00011 *version 2.1 of the License, or (at your option) any later version.
00012 *
00013 *This library is distributed in the hope that it will be useful,
00014 *but WITHOUT ANY WARRANTY; without even the implied warranty of
00015 *MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00016 *Lesser General Public License for more details.
00017 *
00018 *You should have received a copy of the GNU Lesser General Public
00019 *License along with this library; if not, write to the Free Software
00020 *Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA
00021 *
00022 * "@(#) $Id: baciRWcontImpl_T.h,v 1.23 2008/10/01 02:26:45 cparedes Exp $"
00023 *
00024 * who       when        what
00025 * --------  ----------  ----------------------------------------------
00026 * bjeram    2003/02/13  created
00027 
00028 */
00029 
00035 #ifndef __cplusplus
00036 #error This is a C++ include file and cannot be used from plain C
00037 #endif
00038 
00039 #include <baciPcontImpl_T.h>
00040 #include <baciRWcommonImpl_T.h>
00041 #include <ACSErrTypeCommon.h>
00042 
00046 #define INC_ACTION 2
00047 
00050 #define DEC_ACTION 3
00051 
00052 namespace baci {
00053 
00059 
00060 
00061 template <ACS_RW_C>
00062 class baci_EXPORT RWcontImpl : public virtual POA_SK,
00063                                public RWcommonImpl<ACS_RW_TL>,
00064                                public PcontImpl<ACS_P_TL>    
00065 {
00066     
00067     
00068   public:
00074     RWcontImpl(const ACE_CString& name, BACIComponent *component_p, DevIO<TM> *devIO=0, bool flagdeldevIO=false);
00075     
00081     RWcontImpl(bool initValue, const ACE_CString& name, BACIComponent *component_p, DevIO<TM> *devIO=0, bool flagdeldevIO=false);
00082     
00086     virtual ~RWcontImpl();
00087     
00088     /***
00089      * Implementation of async. set_value method
00090      */
00091 /*
00092   virtual ActionRequest setValueAction(BACIComponent* component_p, int callbackID,
00093   const CBDescIn& descIn, BACIValue* value,
00094   Completion& completion, CBDescOut& descOut);
00095 */
00096     
00097     /* --------------- [ Action implementator interface ] -------------- */
00098     
00116     virtual ActionRequest invokeAction(int function,
00117                                        BACIComponent* component_p, 
00118                                        const int &callbackID, 
00119                                        const CBDescIn& descIn, 
00120                                        BACIValue* value, 
00121                                        Completion& completion, 
00122                                        CBDescOut& descOut);
00123     
00124 /* ----------------- [ Other interface ] ----------------- */
00125     
00134     virtual void setValue(BACIProperty* property,
00135                           BACIValue* value, 
00136                           Completion &completion,
00137                           CBDescOut& descOut);
00138     
00142     virtual ActionRequest incrementAction(BACIComponent* component_p, 
00143                                           int callbackID,
00144                                           const CBDescIn& descIn, 
00145                                           BACIValue* value,
00146                                           Completion& completion, 
00147                                           CBDescOut& descOut);
00148 
00152     virtual ActionRequest decrementAction(BACIComponent* component_p, 
00153                                           int callbackID,
00154                                           const CBDescIn& descIn, 
00155                                           BACIValue* value,
00156                                           Completion& completion, 
00157                                           CBDescOut& descOut);
00158     
00159     /* ----------------------------------------------------------------- */
00160     /* ---------------------- [ CORBA interface ] ---------------------- */
00161     /* ----------------------------------------------------------------- */
00162     
00163     /* -------------------- [ RW (cont) interface ] -------------------- */
00164     
00165     virtual TS min_value ();
00166     
00167     virtual TS max_value ();
00168     
00169     virtual void increment (ACS::CBvoid_ptr cb,
00170                             const ACS::CBDescIn & desc);
00171     
00172     virtual void decrement (ACS::CBvoid_ptr cb,
00173                             const ACS::CBDescIn & desc); 
00174 
00175   protected:
00176     virtual bool readCharacteristics();
00177     
00178   private:
00179     // Characteristics
00180     
00181     // RW (cont)
00182     TSM min_value_m;
00183     TSM max_value_m;
00184 };
00185 
00186  }; 
00187 
00188 #endif  /* baciRWcontImpl */
00189 
00190 
00191 
00192 
00193 
00194 
00195 
00196 
00197 

Generated on Thu Jan 12 2012 23:13:50 for ACS-10.0 C++ API by  doxygen 1.7.0