Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

dtpf::Parameter Class Reference

#include <Parameter.h>

Inheritance diagram for dtpf::Parameter:

dtpf::ParameterTreeVertex dtpf::SpecificParameter dtpf::FileParameter dtpf::GroupParameter dtpf::OnOffParameter dtpf::RangeParameter dtpf::TextParameter List of all members.

Detailed Description

Represents a value and the bounds of that parameter.

Parameter itself has a ParameterType which indicates the type of value the parameter represents, and a ParameterUIType representing the preferred user interface to use for input and display of a Parameter.

Parameter is an ParameterTreeVertex with no child vertices.


Public Member Functions

virtual ~Parameter ()
 Release a Parameter's memory.
virtual ParameterType GetParameterType () const
 Get a Parameter's type.
virtual void SetUIType (ParameterUIType uiType)=0
 Set the preferred UI type.
virtual ParameterUIType GetUIType () const
 Get a Parameter's preferred UI type.
virtual uint32 TypeCode () const
 Get the type code identifying the Parameter class.
virtual uint32 FlattenedSize () const
 Returns the number of bytes needed to store a ParameterTreeVertex object in its current state.
virtual void Flatten (uint8 *buffer) const
 Write a ParameterTreeVertex's state to a byte array.
virtual status_t Unflatten (const uint8 *buffer, uint32 size)
 Set an object's state from a byte array.

Protected Member Functions

 Parameter ()
 Constuct an empty Parameter.
 Parameter (const muscle::String &name, ParameterType paramType, ParameterUIType uiType)
 Construct a Parameter with the given name, parameter type and UI type.
 Parameter (const Parameter &that)
 Construct a Parameter from another.
Parameteroperator= (const Parameter &that)
 Assign one Parameter from another.

Protected Attributes

ParameterType m_paramType
 The ParameterType, set by subclasses.
ParameterUIType m_uiType
 The ParameterUIType.


Constructor & Destructor Documentation

virtual dtpf::Parameter::~Parameter  )  [virtual]
 

Release a Parameter's memory.

dtpf::Parameter::Parameter  )  [protected]
 

Constuct an empty Parameter.

dtpf::Parameter::Parameter const muscle::String &  name,
ParameterType  paramType,
ParameterUIType  uiType
[protected]
 

Construct a Parameter with the given name, parameter type and UI type.

Parameters:
name The parameter name.
paramType The type of parameter.
uiType The preferred UI type.

dtpf::Parameter::Parameter const Parameter that  )  [protected]
 

Construct a Parameter from another.

Parameters:
that The Parameter to copy from.


Member Function Documentation

virtual void dtpf::Parameter::Flatten uint8 *  buffer  )  const [virtual]
 

Write a ParameterTreeVertex's state to a byte array.

Parameters:
buffer The byte array to write to. The caller should ensure that this is at least FlattenedSize() bytes in length.

Reimplemented from dtpf::ParameterTreeVertex.

virtual uint32 dtpf::Parameter::FlattenedSize  )  const [virtual]
 

Returns the number of bytes needed to store a ParameterTreeVertex object in its current state.

Overridden to return the flattened size for a particular subclass.

Returns:
The flattened size for a ParameterTreeVertex object.

Reimplemented from dtpf::ParameterTreeVertex.

virtual ParameterType dtpf::Parameter::GetParameterType  )  const [virtual]
 

Get a Parameter's type.

Returns:
The ParameterType.

virtual ParameterUIType dtpf::Parameter::GetUIType  )  const [virtual]
 

Get a Parameter's preferred UI type.

Returns:
The ParamUIType.

Parameter& dtpf::Parameter::operator= const Parameter that  )  [protected]
 

Assign one Parameter from another.

Parameters:
that The Parameter to assign from.
Returns:
A reference to *this.

virtual void dtpf::Parameter::SetUIType ParameterUIType  uiType  )  [pure virtual]
 

Set the preferred UI type.

Parameters:
uiType The new ParamUIType.

Implemented in dtpf::OnOffParameter, dtpf::GroupParameter, dtpf::RangeParameter, dtpf::FileParameter, and dtpf::TextParameter.

virtual uint32 dtpf::Parameter::TypeCode  )  const [virtual]
 

Get the type code identifying the Parameter class.

Returns:
The Parameter class type code.

Implements dtpf::ParameterTreeVertex.

virtual status_t dtpf::Parameter::Unflatten const uint8 *  buffer,
uint32  size
[virtual]
 

Set an object's state from a byte array.

The ParameterTreeVertex implementation recovers the name, parent and node identifier.

Parameters:
buffer The byte array to unflatten from.
size The length of buffer.
Returns:
E_OK if successful

E_BAD_ARGUMENT if buffer is null or size is less than FlattenedSize().

Reimplemented from dtpf::ParameterTreeVertex.


Member Data Documentation

ParameterType dtpf::Parameter::m_paramType [protected]
 

The ParameterType, set by subclasses.

ParameterUIType dtpf::Parameter::m_uiType [protected]
 

The ParameterUIType.


The documentation for this class was generated from the following file:
Generated on Wed Aug 3 07:26:19 2005 for DTPF by  doxygen 1.3.9.1