rtcFunctor.h
Go to the documentation of this file.
00001 /*
00002  * Copyright (C) 2008
00003  * Robert Bosch LLC
00004  * Research and Technology Center North America
00005  * Palo Alto, California
00006  *
00007  * All rights reserved.
00008  *
00009  *------------------------------------------------------------------------------
00010  * project ....: PUMA: Probablistic Unsupervised Model Acquisition
00011  * file .......: Functor.h
00012  * authors ....: Benjamin Pitzer
00013  * organization: Robert Bosch LLC
00014  * creation ...: 08/16/2006
00015  * modified ...: $Date: 2008-11-06 18:14:42 -0800 (Thu, 06 Nov 2008) $
00016  * changed by .: $Author: benjaminpitzer $
00017  * revision ...: $Revision: 558 $
00018  */
00019 #ifndef FUNCTOR_H
00020 #define FUNCTOR_H
00021 
00022 //== INCLUDES ==================================================================
00023 #include "rtc/rtcIOObject.h"
00024 #include <string>
00025 #include <vector>
00026 
00027 //== NAMESPACES ================================================================
00028 namespace rtc {
00029 
00040 class Functor : public IOObject {
00041 public:
00045   typedef std::string StatusMessage;
00046 
00050   typedef std::vector<StatusMessage> StatusMessages;
00051 
00055   class Parameters : public IOObject {
00056   public:
00060     Parameters();
00061 
00065     Parameters(const Parameters& other);
00066 
00070     virtual ~Parameters();
00071 
00075     Parameters& copy(const Parameters& other);
00076 
00080     virtual Parameters* clone() const = 0;
00081 
00085     virtual bool write(OutputHandler &oh) const;
00086 
00090     virtual bool read(InputHandler &ih);
00091 
00092   protected:
00096     Parameters& operator=(const Parameters& other);
00097   };
00098 
00102   Functor();
00103 
00107   Functor(const Functor& other);
00108 
00112   virtual ~Functor();
00113 
00118   virtual bool setParameters(const Parameters& theParam);
00119 
00123   const Parameters& getParameters() const;
00124 
00129   Functor& copy(const Functor& other);
00130 
00134   virtual Functor* clone() const = 0;
00135 
00139   void addStatusMessage(const StatusMessage msg);
00140 
00144   const StatusMessages& getStatusMessages() const;
00145 
00149   virtual bool write(OutputHandler &oh) const;
00150 
00154   virtual bool read(InputHandler &ih);
00155 
00156 private:
00157 
00162   Functor& operator=(const Functor& other);
00163 
00167   Parameters* params;
00168 
00172   StatusMessages m_messages;
00173 };
00174 
00175 //==============================================================================
00176 } // NAMESPACE rtc
00177 //==============================================================================
00178 #endif // FUNCTOR_H defined
00179 //==============================================================================
00180 


rtc
Author(s): Benjamin Pitzer
autogenerated on Mon Oct 6 2014 10:07:34