Dhruvaraj Subhashchandran | 3c6f29a | 2017-04-20 09:47:28 -0500 | [diff] [blame] | 1 | // This file was autogenerated. Do not edit! |
| 2 | // See elog-gen.py for more details |
| 3 | #pragma once |
| 4 | |
| 5 | #include <string> |
| 6 | #include <tuple> |
| 7 | #include <type_traits> |
| 8 | #include <sdbusplus/exception.hpp> |
| 9 | #include <phosphor-logging/log.hpp> |
| 10 | #include <phosphor-logging/elog.hpp> |
| 11 | |
| 12 | namespace sdbusplus |
| 13 | { |
| 14 | namespace xyz |
| 15 | { |
| 16 | namespace openbmc_project |
| 17 | { |
| 18 | namespace Led |
| 19 | { |
| 20 | namespace Fru |
| 21 | { |
| 22 | namespace Monitor |
| 23 | { |
| 24 | namespace Error |
| 25 | { |
| 26 | struct AssociationRetrieveError; |
| 27 | } // namespace Error |
| 28 | } // namespace Monitor |
| 29 | } // namespace Fru |
| 30 | } // namespace Led |
| 31 | } // namespace openbmc_project |
| 32 | } // namespace xyz |
| 33 | } // namespace sdbusplus |
| 34 | |
| 35 | namespace sdbusplus |
| 36 | { |
| 37 | namespace xyz |
| 38 | { |
| 39 | namespace openbmc_project |
| 40 | { |
| 41 | namespace Led |
| 42 | { |
| 43 | namespace Fru |
| 44 | { |
| 45 | namespace Monitor |
| 46 | { |
| 47 | namespace Error |
| 48 | { |
| 49 | struct InventoryPathError; |
| 50 | } // namespace Error |
| 51 | } // namespace Monitor |
| 52 | } // namespace Fru |
| 53 | } // namespace Led |
| 54 | } // namespace openbmc_project |
| 55 | } // namespace xyz |
| 56 | } // namespace sdbusplus |
| 57 | |
| 58 | namespace sdbusplus |
| 59 | { |
| 60 | namespace xyz |
| 61 | { |
| 62 | namespace openbmc_project |
| 63 | { |
| 64 | namespace Led |
| 65 | { |
| 66 | namespace Mapper |
| 67 | { |
| 68 | namespace Error |
| 69 | { |
| 70 | struct ObjectNotFoundError; |
| 71 | } // namespace Error |
| 72 | } // namespace Mapper |
| 73 | } // namespace Led |
| 74 | } // namespace openbmc_project |
| 75 | } // namespace xyz |
| 76 | } // namespace sdbusplus |
| 77 | |
| 78 | namespace sdbusplus |
| 79 | { |
| 80 | namespace xyz |
| 81 | { |
| 82 | namespace openbmc_project |
| 83 | { |
| 84 | namespace Led |
| 85 | { |
| 86 | namespace Mapper |
| 87 | { |
| 88 | namespace Error |
| 89 | { |
| 90 | struct MethodError; |
| 91 | } // namespace Error |
| 92 | } // namespace Mapper |
| 93 | } // namespace Led |
| 94 | } // namespace openbmc_project |
| 95 | } // namespace xyz |
| 96 | } // namespace sdbusplus |
| 97 | |
| 98 | |
| 99 | namespace phosphor |
| 100 | { |
| 101 | |
| 102 | namespace logging |
| 103 | { |
| 104 | |
| 105 | namespace xyz |
| 106 | { |
| 107 | namespace openbmc_project |
| 108 | { |
| 109 | namespace Led |
| 110 | { |
| 111 | namespace Fru |
| 112 | { |
| 113 | namespace Monitor |
| 114 | { |
| 115 | namespace _InventoryPathError |
| 116 | { |
| 117 | |
| 118 | struct PATH |
| 119 | { |
| 120 | static constexpr auto str = "PATH=%s"; |
| 121 | static constexpr auto str_short = "PATH"; |
| 122 | using type = std::tuple<std::decay_t<decltype(str)>,const char*>; |
| 123 | explicit constexpr PATH(const char* a) : _entry(entry(str, a)) {}; |
| 124 | type _entry; |
| 125 | }; |
| 126 | |
| 127 | } // namespace _InventoryPathError |
| 128 | |
| 129 | struct InventoryPathError : public sdbusplus::exception_t |
| 130 | { |
| 131 | static constexpr auto errName = "xyz.openbmc_project.Led.Fru.Monitor.InventoryPathError"; |
| 132 | static constexpr auto errDesc = "Invalid Inventory Path."; |
| 133 | static constexpr auto L = level::INFO; |
| 134 | using PATH = _InventoryPathError::PATH; |
| 135 | using metadata_types = std::tuple<PATH>; |
| 136 | |
| 137 | const char* name() const noexcept |
| 138 | { |
| 139 | return errName; |
| 140 | } |
| 141 | |
| 142 | const char* description() const noexcept |
| 143 | { |
| 144 | return errDesc; |
| 145 | } |
| 146 | |
| 147 | const char* what() const noexcept |
| 148 | { |
| 149 | return errName; |
| 150 | } |
| 151 | }; |
| 152 | |
| 153 | } // namespace Monitor |
| 154 | } // namespace Fru |
| 155 | } // namespace Led |
| 156 | } // namespace openbmc_project |
| 157 | } // namespace xyz |
| 158 | |
| 159 | |
| 160 | namespace details |
| 161 | { |
| 162 | |
| 163 | template <> |
| 164 | struct map_exception_type<sdbusplus::xyz::openbmc_project::Led::Fru::Monitor::Error::InventoryPathError> |
| 165 | { |
| 166 | using type = xyz::openbmc_project::Led::Fru::Monitor::InventoryPathError; |
| 167 | }; |
| 168 | |
| 169 | } |
| 170 | |
| 171 | namespace xyz |
| 172 | { |
| 173 | namespace openbmc_project |
| 174 | { |
| 175 | namespace Led |
| 176 | { |
| 177 | namespace Fru |
| 178 | { |
| 179 | namespace Monitor |
| 180 | { |
| 181 | namespace _AssociationRetrieveError |
| 182 | { |
| 183 | |
| 184 | struct ELOG_ENTRY_PATH |
| 185 | { |
| 186 | static constexpr auto str = "ELOG_ENTRY_PATH=%s"; |
| 187 | static constexpr auto str_short = "ELOG_ENTRY_PATH"; |
| 188 | using type = std::tuple<std::decay_t<decltype(str)>,const char*>; |
| 189 | explicit constexpr ELOG_ENTRY_PATH(const char* a) : _entry(entry(str, a)) {}; |
| 190 | type _entry; |
| 191 | }; |
| 192 | |
| 193 | } // namespace _AssociationRetrieveError |
| 194 | |
| 195 | struct AssociationRetrieveError : public sdbusplus::exception_t |
| 196 | { |
| 197 | static constexpr auto errName = "xyz.openbmc_project.Led.Fru.Monitor.AssociationRetrieveError"; |
| 198 | static constexpr auto errDesc = "Error in retrieving the associations from elog entry."; |
| 199 | static constexpr auto L = level::INFO; |
| 200 | using ELOG_ENTRY_PATH = _AssociationRetrieveError::ELOG_ENTRY_PATH; |
| 201 | using metadata_types = std::tuple<ELOG_ENTRY_PATH>; |
| 202 | |
| 203 | const char* name() const noexcept |
| 204 | { |
| 205 | return errName; |
| 206 | } |
| 207 | |
| 208 | const char* description() const noexcept |
| 209 | { |
| 210 | return errDesc; |
| 211 | } |
| 212 | |
| 213 | const char* what() const noexcept |
| 214 | { |
| 215 | return errName; |
| 216 | } |
| 217 | }; |
| 218 | |
| 219 | } // namespace Monitor |
| 220 | } // namespace Fru |
| 221 | } // namespace Led |
| 222 | } // namespace openbmc_project |
| 223 | } // namespace xyz |
| 224 | |
| 225 | |
| 226 | namespace details |
| 227 | { |
| 228 | |
| 229 | template <> |
| 230 | struct map_exception_type<sdbusplus::xyz::openbmc_project::Led::Fru::Monitor::Error::AssociationRetrieveError> |
| 231 | { |
| 232 | using type = xyz::openbmc_project::Led::Fru::Monitor::AssociationRetrieveError; |
| 233 | }; |
| 234 | |
| 235 | } |
| 236 | |
| 237 | namespace xyz |
| 238 | { |
| 239 | namespace openbmc_project |
| 240 | { |
| 241 | namespace Led |
| 242 | { |
| 243 | namespace Mapper |
| 244 | { |
| 245 | namespace _MethodError |
| 246 | { |
| 247 | |
| 248 | struct METHOD_NAME |
| 249 | { |
| 250 | static constexpr auto str = "METHOD_NAME=%s"; |
| 251 | static constexpr auto str_short = "METHOD_NAME"; |
| 252 | using type = std::tuple<std::decay_t<decltype(str)>,const char*>; |
| 253 | explicit constexpr METHOD_NAME(const char* a) : _entry(entry(str, a)) {}; |
| 254 | type _entry; |
| 255 | }; |
| 256 | struct PATH |
| 257 | { |
| 258 | static constexpr auto str = "PATH=%s"; |
| 259 | static constexpr auto str_short = "PATH"; |
| 260 | using type = std::tuple<std::decay_t<decltype(str)>,const char*>; |
| 261 | explicit constexpr PATH(const char* a) : _entry(entry(str, a)) {}; |
| 262 | type _entry; |
| 263 | }; |
| 264 | struct INTERFACE |
| 265 | { |
| 266 | static constexpr auto str = "INTERFACE=%s"; |
| 267 | static constexpr auto str_short = "INTERFACE"; |
| 268 | using type = std::tuple<std::decay_t<decltype(str)>,const char*>; |
| 269 | explicit constexpr INTERFACE(const char* a) : _entry(entry(str, a)) {}; |
| 270 | type _entry; |
| 271 | }; |
| 272 | |
| 273 | } // namespace _MethodError |
| 274 | |
| 275 | struct MethodError : public sdbusplus::exception_t |
| 276 | { |
| 277 | static constexpr auto errName = "xyz.openbmc_project.Led.Mapper.MethodError"; |
| 278 | static constexpr auto errDesc = "Failed to invoke ObjectMapper method"; |
| 279 | static constexpr auto L = level::INFO; |
| 280 | using METHOD_NAME = _MethodError::METHOD_NAME; |
| 281 | using PATH = _MethodError::PATH; |
| 282 | using INTERFACE = _MethodError::INTERFACE; |
| 283 | using metadata_types = std::tuple<METHOD_NAME, PATH, INTERFACE>; |
| 284 | |
| 285 | const char* name() const noexcept |
| 286 | { |
| 287 | return errName; |
| 288 | } |
| 289 | |
| 290 | const char* description() const noexcept |
| 291 | { |
| 292 | return errDesc; |
| 293 | } |
| 294 | |
| 295 | const char* what() const noexcept |
| 296 | { |
| 297 | return errName; |
| 298 | } |
| 299 | }; |
| 300 | |
| 301 | } // namespace Mapper |
| 302 | } // namespace Led |
| 303 | } // namespace openbmc_project |
| 304 | } // namespace xyz |
| 305 | |
| 306 | |
| 307 | namespace details |
| 308 | { |
| 309 | |
| 310 | template <> |
| 311 | struct map_exception_type<sdbusplus::xyz::openbmc_project::Led::Mapper::Error::MethodError> |
| 312 | { |
| 313 | using type = xyz::openbmc_project::Led::Mapper::MethodError; |
| 314 | }; |
| 315 | |
| 316 | } |
| 317 | |
| 318 | namespace xyz |
| 319 | { |
| 320 | namespace openbmc_project |
| 321 | { |
| 322 | namespace Led |
| 323 | { |
| 324 | namespace Mapper |
| 325 | { |
| 326 | namespace _ObjectNotFoundError |
| 327 | { |
| 328 | |
| 329 | struct METHOD_NAME |
| 330 | { |
| 331 | static constexpr auto str = "METHOD_NAME=%s"; |
| 332 | static constexpr auto str_short = "METHOD_NAME"; |
| 333 | using type = std::tuple<std::decay_t<decltype(str)>,const char*>; |
| 334 | explicit constexpr METHOD_NAME(const char* a) : _entry(entry(str, a)) {}; |
| 335 | type _entry; |
| 336 | }; |
| 337 | struct PATH |
| 338 | { |
| 339 | static constexpr auto str = "PATH=%s"; |
| 340 | static constexpr auto str_short = "PATH"; |
| 341 | using type = std::tuple<std::decay_t<decltype(str)>,const char*>; |
| 342 | explicit constexpr PATH(const char* a) : _entry(entry(str, a)) {}; |
| 343 | type _entry; |
| 344 | }; |
| 345 | struct INTERFACE |
| 346 | { |
| 347 | static constexpr auto str = "INTERFACE=%s"; |
| 348 | static constexpr auto str_short = "INTERFACE"; |
| 349 | using type = std::tuple<std::decay_t<decltype(str)>,const char*>; |
| 350 | explicit constexpr INTERFACE(const char* a) : _entry(entry(str, a)) {}; |
| 351 | type _entry; |
| 352 | }; |
| 353 | |
| 354 | } // namespace _ObjectNotFoundError |
| 355 | |
| 356 | struct ObjectNotFoundError : public sdbusplus::exception_t |
| 357 | { |
| 358 | static constexpr auto errName = "xyz.openbmc_project.Led.Mapper.ObjectNotFoundError"; |
| 359 | static constexpr auto errDesc = "Failed to get response from the method."; |
| 360 | static constexpr auto L = level::INFO; |
| 361 | using METHOD_NAME = _ObjectNotFoundError::METHOD_NAME; |
| 362 | using PATH = _ObjectNotFoundError::PATH; |
| 363 | using INTERFACE = _ObjectNotFoundError::INTERFACE; |
| 364 | using metadata_types = std::tuple<METHOD_NAME, PATH, INTERFACE>; |
| 365 | |
| 366 | const char* name() const noexcept |
| 367 | { |
| 368 | return errName; |
| 369 | } |
| 370 | |
| 371 | const char* description() const noexcept |
| 372 | { |
| 373 | return errDesc; |
| 374 | } |
| 375 | |
| 376 | const char* what() const noexcept |
| 377 | { |
| 378 | return errName; |
| 379 | } |
| 380 | }; |
| 381 | |
| 382 | } // namespace Mapper |
| 383 | } // namespace Led |
| 384 | } // namespace openbmc_project |
| 385 | } // namespace xyz |
| 386 | |
| 387 | |
| 388 | namespace details |
| 389 | { |
| 390 | |
| 391 | template <> |
| 392 | struct map_exception_type<sdbusplus::xyz::openbmc_project::Led::Mapper::Error::ObjectNotFoundError> |
| 393 | { |
| 394 | using type = xyz::openbmc_project::Led::Mapper::ObjectNotFoundError; |
| 395 | }; |
| 396 | |
| 397 | } |
| 398 | |
| 399 | |
| 400 | } // namespace logging |
| 401 | |
| 402 | } // namespace phosphor |