Ardour  9.0-pre0-582-g084a23a80d
Evoral::Parameter Class Reference

#include <Parameter.h>

Public Member Functions

 Parameter (ParameterType type, uint8_t channel=0, uint32_t id=0)
 
ParameterType type () const
 
uint8_t channel () const
 
uint32_t id () const
 
bool operator== (const Parameter &id) const
 
bool operator!= (const Parameter &id) const
 
bool operator< (const Parameter &other) const
 
 operator bool () const
 

Private Attributes

ParameterType _type
 
uint32_t _id
 
uint8_t _channel
 

Detailed Description

ID of a [play|record|automate]able parameter.

A parameter is defined by (type, id, channel). Type is an integer which can be used in any way by the application (e.g. cast to a custom enum, map to/from a URI, etc). ID is type specific (e.g. MIDI controller #).

This class defines a < operator which is a strict weak ordering, so Parameter may be stored in a std::set, used as a std::map key, etc.

Definition at line 42 of file Parameter.h.

Constructor & Destructor Documentation

◆ Parameter()

Evoral::Parameter::Parameter ( ParameterType  type,
uint8_t  channel = 0,
uint32_t  id = 0 
)
inline

Definition at line 45 of file Parameter.h.

Member Function Documentation

◆ channel()

uint8_t Evoral::Parameter::channel ( ) const
inline

Definition at line 50 of file Parameter.h.

◆ id()

uint32_t Evoral::Parameter::id ( ) const
inline

Definition at line 51 of file Parameter.h.

◆ operator bool()

Evoral::Parameter::operator bool ( ) const
inline

Definition at line 82 of file Parameter.h.

◆ operator!=()

bool Evoral::Parameter::operator!= ( const Parameter id) const
inline

Definition at line 62 of file Parameter.h.

◆ operator<()

bool Evoral::Parameter::operator< ( const Parameter other) const
inline

Strict weak ordering See: http://www.sgi.com/tech/stl/StrictWeakOrdering.html Sort Parameters first according to type then to channel and lastly to ID.

Definition at line 70 of file Parameter.h.

◆ operator==()

bool Evoral::Parameter::operator== ( const Parameter id) const
inline

Equivalence operator It is obvious from the definition that this operator is transitive, as required by stict weak ordering (see: http://www.sgi.com/tech/stl/StrictWeakOrdering.html)

Definition at line 58 of file Parameter.h.

◆ type()

ParameterType Evoral::Parameter::type ( ) const
inline

Definition at line 49 of file Parameter.h.

Member Data Documentation

◆ _channel

uint8_t Evoral::Parameter::_channel
private

Definition at line 87 of file Parameter.h.

◆ _id

uint32_t Evoral::Parameter::_id
private

Definition at line 86 of file Parameter.h.

◆ _type

ParameterType Evoral::Parameter::_type
private

Definition at line 85 of file Parameter.h.


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