Class BlackboardVariable<DataType>
A base class for blackboard variables serialized by value.
Inherited Members
Namespace: Unity.Behavior
Assembly: Unity.Behavior.dll
Syntax
[Serializable]
public class BlackboardVariable<DataType> : BlackboardVariable
Type Parameters
Name | Description |
---|---|
DataType | The type of value stored in the variable. |
Constructors
BlackboardVariable()
BlackboardVariable constructor.
Declaration
public BlackboardVariable()
BlackboardVariable(DataType)
BlackboardVariable constructor.
Declaration
public BlackboardVariable(DataType value)
Parameters
Type | Name | Description |
---|---|---|
DataType | value | Datatype |
Fields
m_Value
The value of the blackboard variable.
Declaration
[SerializeField]
protected DataType m_Value
Field Value
Type | Description |
---|---|
DataType |
Properties
ObjectValue
see ObjectValue
Declaration
public override sealed object ObjectValue { get; set; }
Property Value
Type | Description |
---|---|
object |
Overrides
Type
see Type
Declaration
public override Type Type { get; }
Property Value
Type | Description |
---|---|
Type |
Overrides
Value
see ObjectValue
Declaration
public virtual DataType Value { get; set; }
Property Value
Type | Description |
---|---|
DataType |
Methods
Equals(BlackboardVariable)
Declaration
public override bool Equals(BlackboardVariable other)
Parameters
Type | Name | Description |
---|---|---|
BlackboardVariable | other |
Returns
Type | Description |
---|---|
bool |
Overrides
ValueEquals(BlackboardVariable)
Returns true if the values of the two variables are equal and false otherwise.
Declaration
public override bool ValueEquals(BlackboardVariable other)
Parameters
Type | Name | Description |
---|---|---|
BlackboardVariable | other | The variable whose value is compared to. |
Returns
Type | Description |
---|---|
bool | Returns true if the values of the two variables are equal and false otherwise. |
Overrides
ValueEquals(BlackboardVariable<DataType>)
Returns true if the values of the two variables are equal and false otherwise.
Declaration
public bool ValueEquals(BlackboardVariable<DataType> other)
Parameters
Type | Name | Description |
---|---|---|
BlackboardVariable<DataType> | other | The variable whose value is compared to. |
Returns
Type | Description |
---|---|
bool | Returns true if the values of the two variables are equal and false otherwise. |
Operators
explicit operator BlackboardVariable<DataType>(DataType)
Implicit conversion from DataType to BlackboardVariable.
Declaration
public static explicit operator BlackboardVariable<DataType>(DataType value)
Parameters
Type | Name | Description |
---|---|---|
DataType | value | Datatype value used to create a BlackboardVariable |
Returns
Type | Description |
---|---|
BlackboardVariable<DataType> | Returns a Blackboard Variable with the given value. |
implicit operator DataType(BlackboardVariable<DataType>)
Implicit conversion from BlackboardVariable to DataType.
Declaration
public static implicit operator DataType(BlackboardVariable<DataType> value)
Parameters
Type | Name | Description |
---|---|---|
BlackboardVariable<DataType> | value | The variable holding the DataType value |
Returns
Type | Description |
---|---|
DataType | Returns the value stored in the Blackboard Variable. |