23 #include <interfaces/generator/checker.h> 24 #include <interfaces/generator/exceptions.h> 25 #include <interfaces/generator/pseudomap.h> 85 return keytype_ +
"_t";
100 if ((name_.length() == 0) || (name_.find(
" ") != std::string::npos)) {
103 "name must neither be empty nor contain spaces");
105 if (type_.length() == 0) {
108 if ((keytype_ !=
"int8") && (keytype_ !=
"int16") && (keytype_ !=
"int32")
109 && (keytype_ !=
"int64") && (keytype_ !=
"uint8") && (keytype_ !=
"uint16")
110 && (keytype_ !=
"uint32") && (keytype_ !=
"uint64")) {
113 "Pseudo map keys can only be of a numeric type");
115 if (keytype_.length() == 0) {
118 "key type must not be empty");
129 parefs_.push_back(make_pair(fieldname, key));
std::string getName() const
Get name of field.
Thrown if illegal value is supplied.
std::string getComment() const
Get comment of field.
RefList & getRefList()
Get reference list.
std::list< std::pair< std::string, std::string > > RefList
Reference list.
std::string getKeyType() const
Get type of key value.
void addRef(std::string fieldname, std::string key)
Add reference.
void valid()
Assert validity.
InterfacePseudoMap(std::string name, std::string type, std::string keytype, std::string comment)
Constructor.
std::string getType() const
Get type of field.