#include <groupactorproperty.h>

Public Member Functions | |
| GroupActorProperty (const std::string &name, const std::string &label, Functor1< const NamedGroupParameter & > set, Functor0Ret< dtCore::RefPtr< NamedGroupParameter > > get, const std::string &desc, const std::string &groupName, const std::string &editorType="", bool readOnly=false) | |
| Creates a new group actor property. | |
| virtual bool | FromString (const std::string &value) |
| Sets the value of the property based on a string. | |
| virtual const std::string | ToString () const |
| |
| virtual void | CopyFrom (const ActorProperty &otherProp) |
| This is overridden to make handle the fact that the get method returns a refptr. | |
| void | SetValue (const NamedGroupParameter &value) |
| Sets the value of this property by calling the set functor assigned to this property. | |
| dtCore::RefPtr < NamedGroupParameter > | GetValue () const |
| |
| const std::string & | GetEditorType () const |
Protected Member Functions | |
| virtual | ~GroupActorProperty () |
This actor property solves the concept of both structures and lists in actor properties. This property gets and sets a NamedGroupParameter, which can hold any number of other NamedParameters. This is passed to the functors for the actor property which must then handle the data in way that makes sense the actor. Additionally, a string name can be passed to the property in the constructor
Also, note that currently Vec3d and Vec3f parameters will be loaded as Vec3. There are plans to fix this.
| dtDAL::GroupActorProperty::GroupActorProperty | ( | const std::string & | name, | |
| const std::string & | label, | |||
| Functor1< const NamedGroupParameter & > | set, | |||
| Functor0Ret< dtCore::RefPtr< NamedGroupParameter > > | get, | |||
| const std::string & | desc, | |||
| const std::string & | groupName, | |||
| const std::string & | editorType = "", |
|||
| bool | readOnly = false | |||
| ) |
Creates a new group actor property.
| name | the name used to access this property. | |
| label | a more human readable name to use when displaying the property. | |
| desc | a longer description of the property. | |
| set | The setting functor, a method/function taking a const reference to a NamedGroupParameter. | |
| get | The getting functor, a method/function returning a ref ptr to a NamedGroupParameter It returns a refptr because it is expected that the method returning the data will generating the parameter from internal data and won't be holding onto it. | |
| groupName | The property grouping to use when editing properties visually. | |
| editorType | a string specifying what type of editor to use for the data in this group. These will specify a UI to use in STAGE. | |
| readOnly | true if this property should not be editable. Defaults to false. |
| dtDAL::GroupActorProperty::~GroupActorProperty | ( | ) | [protected, virtual] |
| bool dtDAL::GroupActorProperty::FromString | ( | const std::string & | value | ) | [virtual] |
Sets the value of the property based on a string.
| value | the value to set. |
Implements dtDAL::AbstractParameter.
| const std::string dtDAL::GroupActorProperty::ToString | ( | ) | const [virtual] |
This value can be used when calling SetStringValue.
Implements dtDAL::AbstractParameter.
| void dtDAL::GroupActorProperty::CopyFrom | ( | const ActorProperty & | otherProp | ) | [virtual] |
This is overridden to make handle the fact that the get method returns a refptr.
| otherProp | The property to copy from. |
Implements dtDAL::ActorProperty.
| void dtDAL::GroupActorProperty::SetValue | ( | const NamedGroupParameter & | value | ) |
Sets the value of this property by calling the set functor assigned to this property.
| dtCore::RefPtr< NamedGroupParameter > dtDAL::GroupActorProperty::GetValue | ( | ) | const |
| const std::string& dtDAL::GroupActorProperty::GetEditorType | ( | ) | const [inline] |