CrystalSpace

Public API Reference

CS::Utility::iModifiable Struct Reference

This interface is to be implemented by all objects willing to be modified automatically. More...

#include <iutil/modifiable.h>

Inheritance diagram for CS::Utility::iModifiable:

List of all members.

Public Member Functions

virtual void AddListener (iModifiableListener *listener)=0
 Add a listener to the list.
virtual csPtr
< iModifiableDescription
GetDescription (iObjectRegistry *object_reg) const =0
 Returns this object's description.
virtual void GetParameterValue (size_t parameterIndex, csVariant &value) const =0
 Returns the value of one of this object's parameters.
virtual size_t GetTotalParameterCount () const =0
 This method is there only to help securing the current code generation.
virtual void RemoveListener (iModifiableListener *listener)=0
 Remove the given listener from the list.
virtual bool SetParameterValue (size_t parameterIndex, const csVariant &value)=0
 Sets a value for the parameter with the unique identifier id.

Detailed Description

This interface is to be implemented by all objects willing to be modified automatically.

It provide access to the parameters of the CS objects, and to their type, description and constraints.

A iModifiableDescription can be accessed through GetDescription() in order to obtain the description of the list of parameters of this iModifiable.

This mechanism allows for example programs such as cseditor to generate automatically Graphical User Interfaces in order to modify their attributes. It can also be used by any automated process such as an animation or a persistance system.

See also:
iModifiableDescription
iModifiableParameter

Definition at line 202 of file modifiable.h.


Member Function Documentation

virtual void CS::Utility::iModifiable::AddListener ( iModifiableListener listener  )  [pure virtual]

Add a listener to the list.

virtual csPtr<iModifiableDescription> CS::Utility::iModifiable::GetDescription ( iObjectRegistry object_reg  )  const [pure virtual]

Returns this object's description.

virtual void CS::Utility::iModifiable::GetParameterValue ( size_t  parameterIndex,
csVariant value 
) const [pure virtual]

Returns the value of one of this object's parameters.

virtual size_t CS::Utility::iModifiable::GetTotalParameterCount (  )  const [pure virtual]

This method is there only to help securing the current code generation.

This method should therefore be removed once a better code generation system would be implemented.

virtual void CS::Utility::iModifiable::RemoveListener ( iModifiableListener listener  )  [pure virtual]

Remove the given listener from the list.

virtual bool CS::Utility::iModifiable::SetParameterValue ( size_t  parameterIndex,
const csVariant value 
) [pure virtual]

Sets a value for the parameter with the unique identifier id.

Returns:
true if the value can be set, false if a property with that index couldn't be found

The documentation for this struct was generated from the following file:

Generated for Crystal Space 2.1 by doxygen 1.6.1