Guitarix
gx_engine::EnumParameter Class Reference

#include <gx_parameter.h>

Inheritance diagram for gx_engine::EnumParameter:
gx_engine::ParameterV< int > gx_engine::Parameter

Public Member Functions

virtual void writeJSON (gx_system::JsonWriter &jw) const
 
virtual void readJSON_value (gx_system::JsonParser &jp)
 
virtual const value_pairgetValueNames () const
 
virtual int idx_from_id (string v_id)
 
const value_pairget_pair ()
 
 EnumParameter (const string &id, const string &name, const value_pair *vn, bool preset, int *v, int sv, bool ctrl)
 
virtual void serializeJSON (gx_system::JsonWriter &jw)
 
- Public Member Functions inherited from gx_engine::ParameterV< int >
bool set (int val) const
 
int get_value () const
 
virtual void stdJSON_value ()
 
virtual bool on_off_value ()
 
virtual void writeJSON (gx_system::JsonWriter &jw) const
 
virtual void readJSON_value (gx_system::JsonParser &jp)
 
virtual bool compareJSON_value ()
 
virtual void setJSON_value ()
 
virtual bool hasRange () const
 
virtual float getLowerAsFloat () const
 
virtual float getUpperAsFloat () const
 
virtual int idx_from_id (string v_id)
 
 ParameterV (const string &id, const string &name, ctrl_type ctp, bool preset, int *v, int sv, int lv, int uv, bool ctrl)
 
 ~ParameterV ()
 
 ParameterV (gx_system::JsonParser &jp)
 
virtual void serializeJSON (gx_system::JsonWriter &jw)
 
sigc::signal< void, int > & signal_changed ()
 
- Public Member Functions inherited from gx_engine::Parameter
std::string group_id () const
 
 Parameter (const string &id, const string &name, value_type vtp, ctrl_type ctp, bool preset, bool ctrl)
 
 Parameter (gx_system::JsonParser &jp)
 
virtual ~Parameter ()
 
virtual void serializeJSON (gx_system::JsonWriter &jw)
 
virtual void trigger_changed ()
 
bool isUsed () const
 
void setUsed ()
 
void dump (gx_system::JsonWriter *jw)
 
const char * get_typename () const
 
bool isFloat () const
 
bool isInt () const
 
bool isBool () const
 
bool isFile () const
 
bool isString () const
 
ctrl_type getControlType () const
 
bool isControllable () const
 
bool isInPreset () const
 
bool isSavable () const
 
void setSavable (bool v)
 
bool isOutput () const
 
void setOutput (bool v)
 
bool isMaxlevel () const
 
void setMaxlevel (bool v)
 
bool isNoWarning () const
 
void setNoWarning (bool v)
 
const string & id () const
 
const string & group () const
 
string l_group () const
 
const string & name () const
 
string l_name () const
 
const string & desc () const
 
void set_desc (const string &desc)
 
string l_desc () const
 
void set_log_display ()
 
bool is_log_display () const
 
void set_blocked (bool v)
 
bool get_blocked () const
 
void set_midi_blocked (bool v)
 
bool get_midi_blocked () const
 
bool operator== (const Parameter &p) const
 
virtual void stdJSON_value ()=0
 
virtual bool on_off_value ()=0
 
virtual void writeJSON (gx_system::JsonWriter &jw) const =0
 
virtual void readJSON_value (gx_system::JsonParser &jp)=0
 
virtual void setJSON_value ()=0
 
virtual bool compareJSON_value ()=0
 
virtual bool hasRange () const
 
virtual float getLowerAsFloat () const
 
virtual float getUpperAsFloat () const
 
virtual float getStepAsFloat () const
 
virtual const value_pairgetValueNames () const
 
FloatParametergetFloat ()
 
IntParametergetInt ()
 
EnumParametergetEnum ()
 
BoolParametergetBool ()
 
FileParametergetFile ()
 
StringParametergetString ()
 
sigc::signal< void, float > & signal_changed_float ()
 
sigc::signal< void, int > & signal_changed_int ()
 
sigc::signal< void, bool > & signal_changed_bool ()
 
sigc::signal< void, const Glib::ustring & > & signal_changed_string ()
 

Protected Member Functions

 EnumParameter (gx_system::JsonParser &jp)
 
- Protected Member Functions inherited from gx_engine::Parameter
void range_warning (float value, float lower, float upper)
 

Protected Attributes

const value_pairvalue_names
 
- Protected Attributes inherited from gx_engine::ParameterV< int >
int json_value
 
int * value
 
int std_value
 
int lower
 
int upper
 
sigc::signal< void, int > changed
 
int value_storage
 
- Protected Attributes inherited from gx_engine::Parameter
string _id
 
string _name
 
string _group
 
string _desc
 
enum value_type v_type: 3
 
enum ctrl_type c_type: 3
 
unsigned int d_flags: 2
 
bool save_in_preset: 1
 
bool controllable: 1
 
bool do_not_save: 1
 
bool blocked: 1
 
bool midi_blocked: 1
 
bool output: 1
 
bool maxlevel: 1
 
bool nowarn: 1
 
bool used: 1
 

Additional Inherited Members

- Public Types inherited from gx_engine::Parameter
enum  ctrl_type { None , Continuous , Switch , Enum }
 
enum  toggle_type {
  OnOff = 0 , Constant = 1 , Toggle = 2 , Commander = 3 ,
  _Count = 4
}
 
- Static Public Member Functions inherited from gx_engine::Parameter
static const char * value_label (const value_pair &vp)
 
- Protected Types inherited from gx_engine::Parameter
enum  value_type {
  tp_float , tp_int , tp_bool , tp_file ,
  tp_string , tp_special
}
 
enum  display_flags { dtp_normal , dtp_log = 1 }
 
- Static Protected Member Functions inherited from gx_engine::Parameter
static gx_system::JsonParserjp_next (gx_system::JsonParser &jp, const char *key)
 

Detailed Description

Definition at line 350 of file gx_parameter.h.

Constructor & Destructor Documentation

◆ EnumParameter() [1/2]

gx_engine::EnumParameter::EnumParameter ( gx_system::JsonParser jp)
inlineprotected

Definition at line 353 of file gx_parameter.h.

◆ EnumParameter() [2/2]

gx_engine::EnumParameter::EnumParameter ( const string &  id,
const string &  name,
const value_pair vn,
bool  preset,
int *  v,
int  sv,
bool  ctrl 
)

Member Function Documentation

◆ get_pair()

const value_pair & gx_engine::EnumParameter::get_pair ( )
inline

Definition at line 359 of file gx_parameter.h.

◆ getValueNames()

virtual const value_pair * gx_engine::EnumParameter::getValueNames ( ) const
virtual

Reimplemented from gx_engine::Parameter.

Referenced by get_pair().

◆ idx_from_id()

virtual int gx_engine::EnumParameter::idx_from_id ( string  v_id)
virtual

Reimplemented from gx_engine::ParameterV< int >.

◆ readJSON_value()

virtual void gx_engine::EnumParameter::readJSON_value ( gx_system::JsonParser jp)
virtual

Reimplemented from gx_engine::ParameterV< int >.

◆ serializeJSON()

virtual void gx_engine::EnumParameter::serializeJSON ( gx_system::JsonWriter jw)
virtual

Reimplemented from gx_engine::ParameterV< int >.

◆ writeJSON()

virtual void gx_engine::EnumParameter::writeJSON ( gx_system::JsonWriter jw) const
virtual

Reimplemented from gx_engine::ParameterV< int >.

Member Data Documentation

◆ value_names

const value_pair* gx_engine::EnumParameter::value_names
protected

Definition at line 352 of file gx_parameter.h.


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