Ardour  9.0-pre0-582-g084a23a80d
PBD::EnumWriter Class Reference

#include <enumwriter.h>

Classes

struct  EnumRegistration
 

Public Member Functions

void register_distinct (std::string type, std::vector< int >, std::vector< std::string >)
 
void register_bits (std::string type, std::vector< int >, std::vector< std::string >)
 
std::string write (std::string type, int value)
 
int read (std::string type, std::string value)
 
void add_to_hack_table (std::string str, std::string hacked_str)
 

Static Public Member Functions

static EnumWriterinstance ()
 
static void destroy ()
 

Private Types

typedef std::map< std::string, EnumRegistrationRegistry
 

Private Member Functions

 EnumWriter ()
 
 ~EnumWriter ()
 
std::string write_bits (EnumRegistration &, int value)
 
std::string write_distinct (EnumRegistration &, int value)
 
int read_bits (EnumRegistration &, std::string value)
 
int read_distinct (EnumRegistration &, std::string value)
 
int validate (EnumRegistration &er, int value) const
 
int validate_bitwise (EnumRegistration &er, int value) const
 

Private Attributes

Registry registry
 

Static Private Attributes

static EnumWriter_instance
 
static std::map< std::string, std::string > hack_table
 

Detailed Description

Definition at line 51 of file enumwriter.h.

Member Typedef Documentation

◆ Registry

typedef std::map<std::string, EnumRegistration> PBD::EnumWriter::Registry
private

Definition at line 78 of file enumwriter.h.

Constructor & Destructor Documentation

◆ EnumWriter()

PBD::EnumWriter::EnumWriter ( )
private

◆ ~EnumWriter()

PBD::EnumWriter::~EnumWriter ( )
private

Member Function Documentation

◆ add_to_hack_table()

void PBD::EnumWriter::add_to_hack_table ( std::string  str,
std::string  hacked_str 
)

◆ destroy()

static void PBD::EnumWriter::destroy ( )
static

◆ instance()

static EnumWriter& PBD::EnumWriter::instance ( )
static

◆ read()

int PBD::EnumWriter::read ( std::string  type,
std::string  value 
)

◆ read_bits()

int PBD::EnumWriter::read_bits ( EnumRegistration ,
std::string  value 
)
private

◆ read_distinct()

int PBD::EnumWriter::read_distinct ( EnumRegistration ,
std::string  value 
)
private

◆ register_bits()

void PBD::EnumWriter::register_bits ( std::string  type,
std::vector< int >  ,
std::vector< std::string >   
)

◆ register_distinct()

void PBD::EnumWriter::register_distinct ( std::string  type,
std::vector< int >  ,
std::vector< std::string >   
)

◆ validate()

int PBD::EnumWriter::validate ( EnumRegistration er,
int  value 
) const
private

◆ validate_bitwise()

int PBD::EnumWriter::validate_bitwise ( EnumRegistration er,
int  value 
) const
private

◆ write()

std::string PBD::EnumWriter::write ( std::string  type,
int  value 
)

◆ write_bits()

std::string PBD::EnumWriter::write_bits ( EnumRegistration ,
int  value 
)
private

◆ write_distinct()

std::string PBD::EnumWriter::write_distinct ( EnumRegistration ,
int  value 
)
private

Member Data Documentation

◆ _instance

EnumWriter* PBD::EnumWriter::_instance
staticprivate

Definition at line 87 of file enumwriter.h.

◆ hack_table

std::map<std::string,std::string> PBD::EnumWriter::hack_table
staticprivate

Definition at line 88 of file enumwriter.h.

◆ registry

Registry PBD::EnumWriter::registry
private

Definition at line 79 of file enumwriter.h.


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