limboai/doc_classes/BBParam.xml

50 lines
2.2 KiB
XML

<?xml version="1.0" encoding="UTF-8" ?>
<class name="BBParam" inherits="Resource" version="4.1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../doc/class.xsd">
<brief_description>
A base class for typed parameters to be used with BT tasks.
</brief_description>
<description>
A base class for typed parameters.
BBParam can store a blackboard variable name or a raw value of specific type.
*Note*: Don't instantiate. Use specific subclasses instead.
</description>
<tutorials>
</tutorials>
<methods>
<method name="get_type" qualifiers="const">
<return type="int" enum="Variant.Type" />
<description>
Returns expected type of the parameter.
</description>
</method>
<method name="get_value">
<return type="Variant" />
<param index="0" name="p_agent" type="Object" />
<param index="1" name="p_blackboard" type="Blackboard" />
<param index="2" name="p_default" type="Variant" default="null" />
<description>
Returns value of the parameter.
</description>
</method>
</methods>
<members>
<member name="saved_value" type="Variant" setter="set_saved_value" getter="get_saved_value" default="null">
A value that is saved with BBParam resource. The type of value is defined by [method get_type]. Provides the parameter's value, if [member value_source] is [constant SAVED_VALUE].
</member>
<member name="value_source" type="int" setter="set_value_source" getter="get_value_source" enum="BBParam.ValueSource" default="0">
A source for the value of BBParam. See [enum ValueSource].
</member>
<member name="variable" type="String" setter="set_variable" getter="get_variable">
A name of [Blackboard] variable. It is used to retrieve the parameter's value, if [member value_source] is [constant BLACKBOARD_VAR].
</member>
</members>
<constants>
<constant name="SAVED_VALUE" value="0" enum="ValueSource">
Value is stored directly with BBParam resource.
</constant>
<constant name="BLACKBOARD_VAR" value="1" enum="ValueSource">
Value is referenced by a variable name and retrieved from the [Blackboard]. A variable name is stored with BBParam resource.
</constant>
</constants>
</class>