Gazebo Transport

API Reference

11.4.1
gz/transport/parameters/result.hh
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2022 Open Source Robotics Foundation
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16 */
17 
18 #ifndef GZ_TRANSPORT_PARAMETERS_EXCEPTIONS_HH_
19 #define GZ_TRANSPORT_PARAMETERS_EXCEPTIONS_HH_
20 
21 #include <ostream>
22 #include <string>
23 
24 #include "gz/transport/config.hh"
25 #include "gz/transport/parameters/Export.hh"
26 
27 namespace ignition
28 {
29  namespace transport
30  {
31  namespace parameters
32  {
33  // Inline bracket to help doxygen filtering.
34  inline namespace IGNITION_TRANSPORT_VERSION_NAMESPACE {
35  enum class IGNITION_TRANSPORT_PARAMETERS_VISIBLE
37  ParameterResultType {
44  };
45 
50  public: IGNITION_TRANSPORT_PARAMETERS_VISIBLE
51  explicit ParameterResult(ParameterResultType _resultType);
52 
56  public: IGNITION_TRANSPORT_PARAMETERS_VISIBLE
58  ParameterResultType _resultType, const std::string & _paramName);
59 
64  public: IGNITION_TRANSPORT_PARAMETERS_VISIBLE
66  ParameterResultType _resultType,
67  const std::string & _paramName,
68  const std::string & _paramType);
69 
71  public: IGNITION_TRANSPORT_PARAMETERS_VISIBLE
72  ParameterResultType ResultType() const;
73 
75  public: IGNITION_TRANSPORT_PARAMETERS_VISIBLE
76  const std::string & ParamName() const;
77 
79  public: IGNITION_TRANSPORT_PARAMETERS_VISIBLE
80  const std::string & ParamType() const;
81 
84  public: IGNITION_TRANSPORT_PARAMETERS_VISIBLE
85  explicit operator bool() const;
86 
87  private: ParameterResultType resultType;
88  private: std::string paramName;
89  private: std::string paramType;
90  };
91 
93  IGNITION_TRANSPORT_PARAMETERS_VISIBLE
95  }
96  }
97  }
98 }
99 
100 #endif
Definition: gz/transport/AdvertiseOptions.hh:28
STL class.
The return type used in all falible parameters methods.
Definition: gz/transport/parameters/result.hh:47
AlreadyDeclared
Definition: gz/transport/parameters/result.hh:39
IGNITION_TRANSPORT_PARAMETERS_VISIBLE ParameterResult(ParameterResultType _resultType)
Construct.
NotDeclared
Definition: gz/transport/parameters/result.hh:41
ClientTimeout
Definition: gz/transport/parameters/result.hh:42
Unexpected
Definition: gz/transport/parameters/result.hh:43
IGNITION_TRANSPORT_PARAMETERS_VISIBLE ParameterResultType ResultType() const
Return the result type.
STL class.
IGNITION_TRANSPORT_PARAMETERS_VISIBLE std::ostream & operator<<(std::ostream &, const ParameterResult &)
Stream operator, for debug output.
InvalidType
Definition: gz/transport/parameters/result.hh:40
const IGNITION_TRANSPORT_PARAMETERS_VISIBLE std::string & ParamType() const
Return the related parameter type.
const IGNITION_TRANSPORT_PARAMETERS_VISIBLE std::string & ParamName() const
Return the related parameter name.
Success
Definition: gz/transport/parameters/result.hh:38