Tekkotsu Homepage
Demos
Overview
Downloads
Dev. Resources
Reference
Credits

plist::NamedEnumerationBase Class Reference

#include <plistPrimitives.h>

Inheritance diagram for plist::NamedEnumerationBase:

Detailed Description

provides some accessors common across NamedEnumeration types

Definition at line 462 of file plistPrimitives.h.

List of all members.

Public Member Functions

 NamedEnumerationBase ()
 constructor
 NamedEnumerationBase (const NamedEnumerationBase &ne)
 copy constructor
NamedEnumerationBaseoperator= (const std::string &v)
 assignment from string
NamedEnumerationBaseoperator= (const NamedEnumerationBase &ne)
 assignment (doesn't copy strictValue)
virtual NamedEnumerationBaseoperator= (const PrimitiveBase &pb)=0
 assignment (don't assign listeners); doesn't trigger fireValueChanged, subclass should do that from its own operator=() following assignment
virtual void set (long x)=0
 converts from a numeric value, may throw bad_format if strictValue is set
virtual void getPreferredNames (std::map< int, std::string > &names) const =0
 fills names with the names and values for the enum -- needed for generic access to the names (e.g. UI generation)
virtual void getAllNames (std::map< std::string, int > &names) const =0
 fills names with the names and values for the enum -- needed for generic access to the names (e.g. UI generation)
std::string getDescription (bool preferredOnly=true)
 returns a string listing the available symbolic names
void setStrict (bool strict)
 sets strictValue (whether or not to allow assignment from numeric values which don't have a symbolic name)
bool getStrict () const
 returns strictValue (whether or not to allow assignment from numeric values which don't have a symbolic name)

Protected Attributes

bool strictValue
 if true, don't allow conversion from numeric string which doesn't correspond to a named value

Constructor & Destructor Documentation

plist::NamedEnumerationBase::NamedEnumerationBase (  ) 

constructor

Definition at line 464 of file plistPrimitives.h.

plist::NamedEnumerationBase::NamedEnumerationBase ( const NamedEnumerationBase ne  ) 

copy constructor

Definition at line 465 of file plistPrimitives.h.


Member Function Documentation

std::string plist::NamedEnumerationBase::getDescription ( bool  preferredOnly = true  ) 
bool plist::NamedEnumerationBase::getStrict (  )  const

returns strictValue (whether or not to allow assignment from numeric values which don't have a symbolic name)

Definition at line 480 of file plistPrimitives.h.

NamedEnumerationBase& plist::NamedEnumerationBase::operator= ( const NamedEnumerationBase ne  ) 

assignment (doesn't copy strictValue)

Definition at line 467 of file plistPrimitives.h.

void plist::NamedEnumerationBase::setStrict ( bool  strict  ) 

sets strictValue (whether or not to allow assignment from numeric values which don't have a symbolic name)

Definition at line 479 of file plistPrimitives.h.

Referenced by Config::sound_config::sound_config().


Member Data Documentation

if true, don't allow conversion from numeric string which doesn't correspond to a named value

Definition at line 483 of file plistPrimitives.h.

Referenced by getDescription().


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

Tekkotsu v5.1CVS
Generated Mon May 9 04:59:25 2016 by Doxygen 1.6.3