Template Struct variable_map< std::string >

Struct Documentation

template<>
struct variable_map<std::string>

get and set string values in the variable map

Public Static Functions

static std::string getVal(Visitor *V, std::string key)

Get value from the variable map corresponding to a name, and attempt to convert it into an string

Return
integer value
Parameters
  • V: Blackbird Visitor
  • key: variable name
Exceptions
  • invalid_argument: Cannot convert a complex variable to an string
  • invalid_argument: Cannot convert a int variable to an string
  • invalid_argument: Cannot convert a float variable to an string
  • invalid_argument: Cannot convert a bool variable to an string
  • invalid_argument: Variable key not defined

static void setVal(Visitor *V, std::string key, std::string val)

Set a string value in the variable map corresponding to a name

Parameters
  • V: Blackbird Visitor
  • key: variable name
  • val: variable value