Jamba C++ API  5.1.1
NormalizedState Class Reference

Used to communicate the state between the UI and the RT and read/write to stream. More...

#include <NormalizedState.h>

Classes

struct  SaveOrder
 Maintains the order used to save/restore the RT and GUI state. More...
 

Public Member Functions

int copyValuesFrom (NormalizedState const &iSource)
 Copy values from the source (iSource) state to this state. More...
 
int copyValuesTo (NormalizedState &oDestination) const
 Copy values from this to the destination (oDestination) state. More...
 
int findParamIndex (ParamID iParamID) const
 The index for the given param. More...
 
ParamValue get (int iIdx) const
 Gets the param value. More...
 
int getCount () const
 
tresult getNormalizedValue (ParamID iParamID, ParamValue &oValue) const
 Returns the normalized value for the given param id if it exists. More...
 
int16 getVersion () const
 
 NormalizedState (SaveOrder const *iSaveOrder)
 
 NormalizedState (NormalizedState const &other)
 
NormalizedStateoperator= (NormalizedState const &other)
 
virtual tresult readFromStream (Parameters const *iParameters, IBStreamer &iStreamer)
 
void set (int iIdx, ParamValue iParamValue)
 Sets the param value. More...
 
tresult setNormalizedValue (ParamID iParamID, ParamValue iValue)
 Sets the normalized value for the given param id if it exists. More...
 
std::string toString () const
 
virtual tresult writeToStream (Parameters const *iParameters, IBStreamer &oStreamer) const
 
 ~NormalizedState ()
 

Public Attributes

SaveOrder const * fSaveOrder
 
ParamValue * fValues {nullptr}
 

Detailed Description

Used to communicate the state between the UI and the RT and read/write to stream.

Constructor & Destructor Documentation

◆ NormalizedState() [1/2]

NormalizedState ( SaveOrder const *  iSaveOrder)
explicit

◆ ~NormalizedState()

◆ NormalizedState() [2/2]

NormalizedState ( NormalizedState const &  other)

Member Function Documentation

◆ copyValuesFrom()

int copyValuesFrom ( NormalizedState const &  iSource)
inline

Copy values from the source (iSource) state to this state.

This call will only copies the values that this state can handle.

Parameters
iSourcethe source to copy the values from
Returns
the number of values actually copied

◆ copyValuesTo()

int copyValuesTo ( NormalizedState oDestination) const

Copy values from this to the destination (oDestination) state.

This call will only copies the values that oDestination state can handle.

Parameters
oDestinationthe destination to copy the values to
Returns
the number of values actually copied

◆ findParamIndex()

int findParamIndex ( ParamID  iParamID) const

The index for the given param.

Returns
the index or -1 if not found

◆ get()

ParamValue get ( int  iIdx) const
inline

Gets the param value.

◆ getCount()

int getCount ( ) const
inline

◆ getNormalizedValue()

tresult getNormalizedValue ( ParamID  iParamID,
ParamValue &  oValue 
) const

Returns the normalized value for the given param id if it exists.

Returns
kResultTrue if the value existed and oValue is populated, kResultFalse otherwise

◆ getVersion()

int16 getVersion ( ) const
inline

◆ operator=()

NormalizedState & operator= ( NormalizedState const &  other)

◆ readFromStream()

tresult readFromStream ( Parameters const *  iParameters,
IBStreamer &  iStreamer 
)
virtual

◆ set()

void set ( int  iIdx,
ParamValue  iParamValue 
)
inline

Sets the param value.

◆ setNormalizedValue()

tresult setNormalizedValue ( ParamID  iParamID,
ParamValue  iValue 
)

Sets the normalized value for the given param id if it exists.

Returns
kResultTrue if the param existed, kResultFalse otherwise

◆ toString()

std::string toString ( ) const

◆ writeToStream()

tresult writeToStream ( Parameters const *  iParameters,
IBStreamer &  oStreamer 
) const
virtual

Member Data Documentation

◆ fSaveOrder

SaveOrder const* fSaveOrder

◆ fValues

ParamValue* fValues {nullptr}

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