NTRT Simulator
v1.1
|
#include <tgObserver.h>
Public Member Functions | |
virtual | ~tgObserver () |
virtual void | onStep (Subject &subject, double dt)=0 |
virtual void | onAttach (Subject &subject) |
virtual void | onSetup (Subject &subject) |
virtual void | onTeardown (Subject &subject) |
A mixin class which makes its derived class the Subject in the Obsever design pattern. These are typically controllers.
Definition at line 35 of file tgObserver.h.
|
inlinevirtual |
A class with virtual member functions must have a virtual destructor.
Definition at line 40 of file tgObserver.h.
|
inlinevirtual |
Notify the observers when an attach action has occurred. Will only occur once, typically before setup
[in,out] | subject | the subject being observed |
Reimplemented in tgCPGActuatorControl, and tgSCASineControl.
Definition at line 55 of file tgObserver.h.
|
inlinevirtual |
Notify the observers when a setup action has occurred.
[in,out] | subject | the subject being observed |
Reimplemented in SerializedSpineControl, BaseSpineCPGControl, SpineFeedbackControl, T6RestLengthController, T6RestLengthController, VerticalSpineRestLengthController, SuperBallPrefLengthController, SuperBallPrefLengthController, T6TensionController, EscapeController, Escape_T6Controller, Escape_T6Controller, OctaCLSine, LearningSpineSine, colSpineSine, htSpineSine, and tgCPGCableControl.
Definition at line 61 of file tgObserver.h.
|
pure virtual |
Notify the observers when a step action has occurred.
[in,out] | subject | the subject being observed |
[in] | the | number of seconds since the previous call; must be positive |
Implemented in SerializedSpineControl, SerializedSineWaves, BaseSpineCPGControl, SpineFeedbackControl, NestedStructureSineWaves, T6RestLengthController, T6RestLengthController, VerticalSpineRestLengthController, T6TensionController, SuperBallPrefLengthController, SuperBallPrefLengthController, EscapeController, tgCPGActuatorControl, Escape_T6Controller, Escape_T6Controller, OctaCLSine, tgCPGLogger, LearningSpineSine, colSpineSine, htSpineSine, tgSCASineControl, tgSineStringControl, tgCPGCableControl, ContactTestController, tgCPGStringControl_mod, and BuildTestController.
|
inlinevirtual |
Notify the observers when a teardown action has occurred.
[in,out] | subject | the subject being observed |
Reimplemented in BaseSpineCPGControl, SpineFeedbackControl, SuperBallPrefLengthController, EscapeController, Escape_T6Controller, Escape_T6Controller, OctaCLSine, LearningSpineSine, colSpineSine, and htSpineSine.
Definition at line 67 of file tgObserver.h.