Rigid Body Dynamics Library
rbdl_errors.h
Go to the documentation of this file.
1/*
2 * RBDL - Rigid Body Dynamics Library
3 * Copyright (c) 2019 Felix Richter <judge@felixrichter.tech>
4 *
5 * Licensed under the zlib license. See LICENSE for more details.
6 */
7#ifndef RBDL_ERRORS_H
8#define RBDL_ERRORS_H
9
10#include <string>
11#include <exception>
12#include "rbdl/rbdl_config.h"
13
14namespace RigidBodyDynamics
15{
16
18namespace Errors
19{
20
34class RBDL_DLLAPI RBDLError : public std::exception
35{
36protected:
37 std::string text;
38public:
39 RBDLError(std::string text);
40 virtual const char* what() const noexcept;
41};
42
43
52class RBDL_DLLAPI RBDLInvalidParameterError : public RBDLError
53{
54public:
55 RBDLInvalidParameterError(std::string text);
56};
57
58
67class RBDL_DLLAPI RBDLSizeMismatchError : public RBDLError
68{
69public:
70 RBDLSizeMismatchError(std::string text);
71};
72
73
82class RBDL_DLLAPI RBDLDofMismatchError : public RBDLError
83{
84public:
85 RBDLDofMismatchError(std::string text);
86};
87
88
97{
98public:
99 RBDLMissingImplementationError(std::string text);
100};
101
109class RBDL_DLLAPI RBDLInvalidFileError : public RBDLError
110{
111public:
112 RBDLInvalidFileError(std::string text);
113};
114
115
124class RBDL_DLLAPI RBDLFileParseError : public RBDLError
125{
126public:
127 RBDLFileParseError(std::string text);
128};
129
130}
131}
132
133#endif
134
Thrown if there is a dof mismatch.
Definition: rbdl_errors.h:83
Base class for all RBDL exceptions.
Definition: rbdl_errors.h:35
Thrown if the file beeing read contains errors.
Definition: rbdl_errors.h:125
Thrown if the specified file could not be found/read.
Definition: rbdl_errors.h:110
Thrown if parameter of function was faulty.
Definition: rbdl_errors.h:53
Thrown if code path reaches a point that is not implmented yet.
Definition: rbdl_errors.h:97
Thrown if there is a size mismatch that prevents further calculations.
Definition: rbdl_errors.h:68