Public Member Functions
ArrayParameter Class Reference

Detailed Description

An ArrayParameter is a specialization of a Parameter.

Deprecated:
Supernova This class is obsolete and replaced by ShaderArrayParameter. It will continue to work, however, but with a limited utility.
See also:
Parameter
Since:
4.0

#include <xsi_arrayparameter.h>

Inheritance diagram for ArrayParameter:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 ArrayParameter ()
 ~ArrayParameter ()
 ArrayParameter (const CRef &in_ref)
 ArrayParameter (const ArrayParameter &in_obj)
bool IsA (siClassID in_ClassID) const
siClassID GetClassID () const
ArrayParameteroperator= (const ArrayParameter &in_obj)
ArrayParameteroperator= (const CRef &in_ref)
Parameter operator[] (LONG in_index)
LONG GetCount (void) const
Parameter Add (void)
CStatus Remove (LONG in_lIndex)
CStatus Remove (const Parameter &in_parameter)
CStatus Move (LONG in_lIndex, LONG in_lUpDown)
CStatus Move (const Parameter &in_parameter, LONG in_lUpDown)
Parameter Add (const CValue &)

Constructor & Destructor Documentation

Constructs an ArrayParameter object.

Destroys an ArrayParameter object.

ArrayParameter ( const CRef in_ref)

Constructs an ArrayParameter object from a reference to another ArrayParameter object.

Parameters:
in_refA reference to a group.
ArrayParameter ( const ArrayParameter in_obj)

Constructs a new ArrayParameter object from an existing ArrayParameter object.

Parameters:
in_objAn existing Group object to copy into this Group object.

Member Function Documentation

bool IsA ( siClassID  in_ClassID) const [virtual]

Returns true if this object supports the functionality of a specified class. For example, an ArrayParameter is a type of Parameter, so an ArrayParameter object supports Parameter functionality.

Parameters:
in_ClassIDTest if this object supports this class.
Returns:
True if this object supports the specified class, and false otherwise.

Reimplemented from Parameter.

siClassID GetClassID ( ) const [virtual]

Returns the class ID for this object.

Returns:
The class ID.

Reimplemented from Parameter.

ArrayParameter& operator= ( const ArrayParameter in_obj)

Assigns an ArrayParameter object to an existing ArrayParameter object.

Parameters:
in_objAn ArrayParameter object to be copied into this object.
Returns:
The reinitialized ArrayParameter object.
ArrayParameter& operator= ( const CRef in_ref)

Assigns a CRef to this ArrayParameter object. The ArrayParameter object is cleared if the CRef is not a reference to an object that supports the ArrayParameter class.

Parameters:
in_refA reference to an object that supports the ArrayParameter class.
Returns:
The reinitialized ArrayParameter object.

Reimplemented from Parameter.

Parameter operator[] ( LONG  in_index)

Returns the parameter at a given index. If the index is out of bounds, this operator returns an empty, invalid Parameter object.

Parameters:
in_indexInteger index of the parameter to get.
Returns:
The parameter at the given index
Empty parameter if the index is out of bounds
LONG GetCount ( void  ) const

Returns the size of the array. If the array is empty or invalid, GetCount returns 0.

Returns:
The number of parameters in the array.
Parameter Add ( void  )

Appends a new parameter to this array. The type of the new parameter is determined by the SPDL definition of the array parameter.

Returns:
The new parameter.
CStatus Remove ( LONG  in_lIndex)

Removes a parameter from the array given its index.

Parameters:
in_lIndexThe index of the parameter to remove.
Returns:
CStatus::OK if succeeded.
CStatus::Fail if the index is out of bounds.
CStatus Remove ( const Parameter in_parameter)

Removes a parameter from the array.

Parameters:
in_parameterIndex of the parameter to remove.
Returns:
CStatus::OK if successful.
CStatus::Fail if the parameter is not a member of the array.
CStatus Move ( LONG  in_lIndex,
LONG  in_lUpDown 
)

Moves a parameter up or down in the array relative to its current position. The new position of the parameter is calculated by adding in_lUpDown to the current index and clamping the result to the array boundaries (0 to ArrayParameter::GetCount - 1).

Parameters:
in_lIndexThe index of the parameter to move.
in_lUpDownPositive or negative amount to move the parameter.
Returns:
CStatus::OK if successful.
CStatus::Fail if the index is out of bounds.
CStatus Move ( const Parameter in_parameter,
LONG  in_lUpDown 
)

Moves a given parameter up or down in the array relative to its current position. The new position of the parameter is calculated by adding in_lUpDown to the current index and clamping the result to the array boundaries (0 to ArrayParameter::GetCount - 1).

Parameters:
in_parameterThe parameter to move.
in_lUpDownPositive or negative amount to move the parameter.
Returns:
CStatus::OK if successful.
CStatus::Fail if the given parameter is not a member of the array.
Parameter Add ( const CValue )

Appends a new parameter to the array. The parameter is initialized with the specified value. The parameter type is determined by the SPDL definition of the array. If the specified value does not match the type specified in the SPDL, Add returns an invalid Parameter object. Use this function to add items to shaders such as the camera lens flare shader, which have object and light lists.

Returns:
The new parameter.

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