Overview

This module is intended to manage behaviors.

Methods

bool preloadBehavior (const string& name)

Load a behavior from its directory name

name

The behavior directory name

Returns

Returns true if it was successfully loaded.

void runBehavior (const string& name)

Run a behavior

name

The behavior directory name

void stopBehavior (const string& name)

Stop a behavior

name

The behavior directory name

void stopAllBehaviors ()

Stop all behaviors

bool removeBehavior (const string& name)

Remove a behavior from the filesystem

name

The behavior directory name

Returns

Return true if succeeded, else false

bool isBehaviorInstalled (const string& name)

Tell if supplied name corresponds to a valid behavior

name

The behavior directory name

Returns

Returns true if it is a valid behavior

vector<string> getInstalledBehaviors ()

Get installed behaviors names

Returns

Returns the behaviors list.

bool isBehaviorRunning (const string& name)

Tell if supplied name corresponds to a running behavior

name

The behavior directory name

Returns

Returns true if it is a running behavior

vector<string> getRunningBehaviors ()

Get running behaviors

Returns

Return running behaviors

void addDefaultBehavior (const string& name)

Set the given behavior as default

name

The behavior name

void removeDefaultBehavior (const string& name)

Remove the given behavior from the default behaviors

name

The behavior directory name

vector<string> getDefaultBehaviors ()

Get default behaviors

Returns

Return default behaviors

void playDefaultProject ()

Play default behaviors


Methods inherited from ALModule

void exit ()

Exits and unregisters the module.

string version ()

Returns the version of the module.

Returns

A string containing the version of the module.

bool ping ()

Just a ping. Always returns true

Returns

returns true

vector<string> getMethodList ()

Retrieves the module's method list.

Returns

An array of method names.

AL::ALValue getMethodHelp (const string& methodName)

Retrieves a method's description.

methodName

The name of the method.

Returns

A structure containing the method's description.

AL::ALValue getModuleHelp ()

Retrieves the module's description.

Returns

A structure describing the module.

string getBrokerName ()

Gets the name of the parent broker.

Returns

The name of the parent broker.

string getUsage (const string& name)

Gets the method usage string. This summarise how to use the method.

name

The name of the method.

Returns

A string that summarises the usage of the method.


Copyright © 2010 Aldebaran Robotics - All rights reserved