KaCanOpen
 All Classes Functions Variables Typedefs Enumerations Pages
Public Types | Public Member Functions | List of all members
kaco::dictionary_error Class Reference

This type of exception is thrown if there are problems accessing the object dictionary or arguments don't match the type of a dictionary entry. You can get the type of the error via get_type() and the name of the causing entry via get_entry_name(). More...

#include <dictionary_error.h>

Inheritance diagram for kaco::dictionary_error:
Inheritance graph
[legend]
Collaboration diagram for kaco::dictionary_error:
Collaboration graph
[legend]

Public Types

enum  type {
  unknown_entry, read_only, write_only, wrong_type,
  mapping_size, mapping_overlap, unknown_operation, unknown_constant
}
 Exact type of the error.
 

Public Member Functions

 dictionary_error (type error_type, const std::string &entry_name, const std::string &additional_information="")
 Constructor. More...
 
virtual ~dictionary_error ()
 Destructor.
 
virtual const char * what () const noexceptoverride
 Returns error description.
 
type get_type () const noexcept
 Returns type of the error.
 
std::string get_entry_name () const noexcept
 Returns the name of the dictionary entry.
 
- Public Member Functions inherited from kaco::canopen_error
 canopen_error (std::string what)
 Constructor. More...
 
virtual ~canopen_error ()
 Destructor.
 

Detailed Description

This type of exception is thrown if there are problems accessing the object dictionary or arguments don't match the type of a dictionary entry. You can get the type of the error via get_type() and the name of the causing entry via get_entry_name().

Definition at line 49 of file dictionary_error.h.

Constructor & Destructor Documentation

kaco::dictionary_error::dictionary_error ( type  error_type,
const std::string &  entry_name,
const std::string &  additional_information = "" 
)
explicit

Constructor.

Parameters
error_typeType of the error
entry_nameName of the dictionary entry
additional_informationAdditional information, appended to the error type string in what()

Definition at line 36 of file dictionary_error.cpp.


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