Tekkotsu Homepage
Demos
Overview
Downloads
Dev. Resources
Reference
Credits

Aibo3DControllerBehavior Class Reference

#include <Aibo3DControllerBehavior.h>

Inheritance diagram for Aibo3DControllerBehavior:

Inheritance graph
[legend]
List of all members.

Detailed Description

Listens to aibo3d control commands coming in from the command port.

Definition at line 21 of file Aibo3DControllerBehavior.h.

Public Member Functions

 Aibo3DControllerBehavior ()
 constructor
virtual ~Aibo3DControllerBehavior ()
 destructor
virtual void DoStart ()
 By default, merely adds to the reference counter (through AddReference()); Note you should still call this from your overriding methods.
virtual void DoStop ()
 By default, subtracts from the reference counter (RemoveReference()), and thus may deletex if zero; Don't forget to still call this when you override this; Warning: call this at the end of your DoStop(), not beginning (it might delete this ).
virtual std::string getGUIType () const
 returns string corresponding to the Java GUI which should be launched
virtual unsigned int getPort () const
 returns port number the Java GUI should connect to
virtual std::string getDescription () const
 Gives a short description of what this particular instantiation does (in case a more specific description is needed on an individual basis).

Static Public Member Functions

static std::string getClassDescription ()
 Gives a short description of what this class of behaviors does... you should override this (but don't have to).
static void setSerializerControl (BehaviorSwitchControlBase *ctrl)
 sets the BehaviorSwitchControlBase which should be used to activate the serialization of WorldState data for the Aibo3D client to read

Private Member Functions

 Aibo3DControllerBehavior (const Aibo3DControllerBehavior &)
 don't call
Aibo3DControllerBehavior operator= (const Aibo3DControllerBehavior &)

Private Attributes

bool launchedSerializer
 if true, indicates we launched the WorldState serializer, so we should stop it again if we stop

Static Private Attributes

static BehaviorSwitchControlBasestateSerializerControl = NULL
 so we can start the serializer behavior if it's not already running


Member Function Documentation

static std::string Aibo3DControllerBehavior::getClassDescription (  )  [inline, static]

Gives a short description of what this class of behaviors does... you should override this (but don't have to).

If you do override this, also consider overriding getDescription() to return it

Reimplemented from BehaviorBase.

Definition at line 44 of file Aibo3DControllerBehavior.h.

Referenced by getDescription().

virtual std::string Aibo3DControllerBehavior::getDescription (  )  const [inline, virtual]

Gives a short description of what this particular instantiation does (in case a more specific description is needed on an individual basis).

By default simply returns getName(), because any calls from a BehaviorBase function to getClassDescription() are going to call BehaviorBase::getClassDescription(), not ~YourSubClass~getClassDescription(), because static functions can't be virtual in C++ (doh!)

This means that getDescription called on a pointer to a BehaviorBase of unknown subtype would always return an empty string, which is pretty useless. So instead we return the name in this situation. If you want getDescription to return getClassDescription, you'll have to override it in your subclass to do so.

Reimplemented from BehaviorBase.

Definition at line 50 of file Aibo3DControllerBehavior.h.

Aibo3DControllerBehavior Aibo3DControllerBehavior::operator= ( const Aibo3DControllerBehavior  )  [private]

don't call


The documentation for this class was generated from the following files:

Tekkotsu v3.0
Generated Fri May 11 20:07:43 2007 by Doxygen 1.4.7