Public Member Functions | Static Public Attributes

FBPropertyBaseAnimatableEnum< tType > Class Template Reference

Search for all occurrences

Detailed Description

template<class tType>
class FBPropertyBaseAnimatableEnum< tType >

Base template class for enum properties.

Definition at line 1508 of file fbproperties.h.

#include <fbproperties.h>

Inheritance diagram for FBPropertyBaseAnimatableEnum< tType >:
Inheritance graph
[legend]

List of all members.

Public Member Functions

  FBPropertyBaseAnimatableEnum ()
  Constructor.
  ~FBPropertyBaseAnimatableEnum ()
  Destructor.
  FBPropertyBaseAnimatableEnum (const FBPropertyBaseAnimatableEnum< tType > &pValue)
  FBPropertyBaseAnimatableEnum.
  operator tType () const
  Overloaded cast to tType operator.
virtual char *  EnumList (int pIndex) override
  Return the string of an enum value.
virtual char *  AsString () override
  Get as string.
virtual bool  SetString (char *pString) override
  Set string for list.
void  operator= (tType pValue)
  Overloaded = operator.

Static Public Attributes

static const char *  mStrings []
  String list.

Constructor & Destructor Documentation

Constructor.

Definition at line 1517 of file fbproperties.h.

{}  

Destructor.

Definition at line 1520 of file fbproperties.h.

    {
    }  
FBPropertyBaseAnimatableEnum ( const FBPropertyBaseAnimatableEnum< tType > &  pValue ) [inline]

FBPropertyBaseAnimatableEnum.

Parameters:
pValue FBPropertyBaseAnimatableEnum.

Definition at line 1527 of file fbproperties.h.

{ operator=((tType)pValue ); }

Member Function Documentation

void operator= ( tType  pValue ) [inline]

Overloaded = operator.

Set the value of the current object using Set function.

Parameters:
pValue Value to set for object.

Definition at line 1534 of file fbproperties.h.

{ SetData( &pValue ); }
operator tType ( ) const [inline]

Overloaded cast to tType operator.

Get the value of the current object using Get fuction.

Returns:
tType cast of current object.

Definition at line 1541 of file fbproperties.h.

{ tType Value; GetData( &Value,sizeof(Value) ); return Value; } 
virtual char* EnumList ( int  pIndex ) [inline, override, virtual]

Return the string of an enum value.

Parameters:
pIndex Enum value to get string for.
Returns:
String value of enum specified by pIndex.

Reimplemented from FBProperty.

Definition at line 1543 of file fbproperties.h.

    {   
        if( IsInternal() )
        {
            return FBProperty::EnumList( pIndex );
        }
        else if(mStrings)
        {
            return (char *)mStrings[pIndex]; 
        }
        else
        {
            assert(mStrings || IsInternal());
            return NULL;
        }
    }
virtual char* AsString ( ) [inline, override, virtual]

Get as string.

Returns:
String list.

Reimplemented from FBProperty.

Definition at line 1563 of file fbproperties.h.

{ return EnumList( AsInt() );}
virtual bool SetString ( char *  pString ) [inline, override, virtual]

Set string for list.

Parameters:
pString String to set for list.

Reimplemented from FBProperty.

Definition at line 1568 of file fbproperties.h.

    {
        int         Count=0;
        const char *    tmpstr;
        while ((tmpstr=EnumList( Count ))!=NULL) {
            if (strcmp(tmpstr,pString)==0) {
                SetData( &Count );
                return true;
            }
            Count++;
        }
        return false;
    }

Member Data Documentation

const char* mStrings[] [static]

String list.

Definition at line 1513 of file fbproperties.h.


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