47 #ifndef _MIRA_MICROUNIT_H_ 48 #define _MIRA_MICROUNIT_H_ 79 mRecoverInterval(
Duration::seconds(1))
85 template<
typename Reflector>
89 r.property(
"RecoverInterval", mRecoverInterval,
99 virtual void checkin(
const std::string& ns,
const std::string& name);
110 const std::string& name);
130 virtual void start();
212 virtual void needRecovery(
const std::string& reason =
"");
246 boost::shared_ptr<PropertyNode> mProperties;
void recoverIntern(const Timer &timer)
virtual void needRecovery(const std::string &reason="")
Can be called to signal that this unit needs recovery.
boost::shared_ptr< MicroUnit > MicroUnitPtr
Definition: MicroUnit.h:254
virtual void operational()
Must be called to reset bootup and recover state by signaling that this unit is fully operational...
virtual void recover()
Overload this method in derived class.
Definition: MicroUnit.h:226
Normally authorities must have a unique name.
Definition: Authority.h:104
Class representing timers and tasks that can be registered and executed by the dispatcher thread...
Definition: DispatcherThread.h:146
bool inRecoveryMode() const
Return true, if the unit is in recovery mode.
Definition: MicroUnit.h:229
specialize cv::DataType for our ImgPixel and inherit from cv::DataType<Vec>
Definition: IOService.h:67
virtual void pause()
Overload this method in derived class.
Definition: MicroUnit.h:195
#define MIRA_REFLECT_BASE(reflector, BaseClass)
Macro that can be used to reflect the base class easily.
Definition: ReflectorInterface.h:912
MicroUnit(Flags flags=NORMAL)
Definition: MicroUnit.h:76
RootPropertyNode mPropertiesRoot
Definition: MicroUnit.h:240
virtual void checkin(const std::string &ns, const std::string &name)
Gets called by a higher application level to check ourself in.
virtual void finalize()
Overload this method in derived class.
Definition: MicroUnit.h:203
Provides MIRA_CLASS_SERIALIZATION macro and includes the major headers of the serialization framework...
Flags
Flags for creating an authority.
Definition: Authority.h:101
A more complex unit that adds a default timer to the thread dispatcher of the authority that acts as ...
Definition: Unit.h:63
virtual void initialize()
Overwrite this method to publish own or subscribe to channels.
Definition: MicroUnit.h:177
void reflect(Reflector &r)
Definition: MicroUnit.h:86
sec_type seconds() const
Returns normalized number of seconds (0..59)
Definition: Time.h:280
Use this class to represent time durations.
Definition: Time.h:106
A special node that acts only as (empty) root node for a property tree.
Definition: PropertyNode.h:448
The object class acts as a generic base class for classes which should be used with the classFactory...
Definition: Object.h:144
void setPropertyNode(boost::shared_ptr< PropertyNode > node)
Sets the main property node.
Authorities act as a facade to the framework.
Definition: Authority.h:94
#define MIRA_OBJECT(classIdentifier)
Use this MACRO if you like the factory to automatically extract the class name from the given identif...
Definition: FactoryMacros.h:179
virtual void destruct()
Notifies this Unit that it is going to be destructed.
virtual void stop()
Stops the unit by performing following steps.
virtual void resume()
Overload this method in derived class.
Definition: MicroUnit.h:186
virtual void start()
Starts the unit by performing following steps.
The framework that holds all manager classes and provides startup and shutdown of all framework relat...
virtual boost::shared_ptr< PropertyNode > getProperties()
see Authority::getProperties()
Provides definition for getters and setters that are used with the serialization framework.
virtual ~MicroUnit()
Destructor checks out our authority.
Units are basic modules of a complex application.
Definition: MicroUnit.h:69