pjmsg_mcap_wrapper
Loading...
Searching...
No Matches
BadParamException.h
Go to the documentation of this file.
1// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima).
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15#ifndef _FASTCDR_EXCEPTIONS_BADPARAMEXCEPTION_H_
16#define _FASTCDR_EXCEPTIONS_BADPARAMEXCEPTION_H_
17
18#include "Exception.h"
19
20namespace eprosima {
21namespace fastcdr {
22namespace exception {
23/*!
24 * @brief This class is thrown as an exception when an invalid parameter is being serialized.
25 * @ingroup EXCEPTIONMODULE
26 */
28{
29public:
30
31 /*!
32 * @brief Default constructor.
33 *
34 * @param message An error message. This message pointer is copied.
35 */
37 const char* const& message) noexcept;
38
39 /*!
40 * @brief Default copy constructor.
41 *
42 * @param ex BadParamException that will be copied.
43 */
45 const BadParamException& ex) noexcept;
46
47 /*!
48 * @brief Default move constructor.
49 *
50 * @param ex BadParamException that will be moved.
51 */
53 BadParamException&& ex) noexcept;
54
55 /*!
56 * @brief Assigment operation.
57 *
58 * @param ex BadParamException that will be copied.
59 */
61 const BadParamException& ex) noexcept;
62
63 /*!
64 * @brief Assigment operation.
65 *
66 * @param ex BadParamException that will be moved.
67 */
69 BadParamException&& ex) noexcept;
70
71 //! @brief Default destructor
72 virtual Cdr_DllAPI ~BadParamException() noexcept;
73
74 //! @brief This function throws the object as exception.
75 Cdr_DllAPI void raise() const override;
76
77 //! @brief Default message used in the library.
78 static Cdr_DllAPI const char* const BAD_PARAM_MESSAGE_DEFAULT;
79};
80} //namespace exception
81} //namespace fastcdr
82} //namespace eprosima
83#endif // _FASTCDR_EXCEPTIONS_BADPARAMEXCEPTION_H_
This class is thrown as an exception when an invalid parameter is being serialized.
virtual Cdr_DllAPI ~BadParamException() noexcept
Default destructor.
Cdr_DllAPI BadParamException & operator=(const BadParamException &ex) noexcept
Assigment operation.
static Cdr_DllAPI const char *const BAD_PARAM_MESSAGE_DEFAULT
Default message used in the library.
Cdr_DllAPI void raise() const override
This function throws the object as exception.
This abstract class is used to create exceptions.
Definition Exception.h:30
#define Cdr_DllAPI
Definition fastcdr_dll.h:51
Definition Cdr.h:49