blob: aba1b6ac7d634f8680a60b75a6323a0538492265 [file] [log] [blame]
Gunnar Mills93c12d32017-05-10 13:11:53 -05001// This file was autogenerated. Do not edit!
2// See elog-gen.py for more details
3#pragma once
4
Gunnar Millsb0ce9962018-09-07 13:39:10 -05005#include <phosphor-logging/elog.hpp>
6#include <phosphor-logging/log.hpp>
7#include <sdbusplus/exception.hpp>
Adriana Kobylak58aa7502020-06-08 11:12:11 -05008
Gunnar Mills93c12d32017-05-10 13:11:53 -05009#include <string>
10#include <tuple>
11#include <type_traits>
Gunnar Mills93c12d32017-05-10 13:11:53 -050012
13namespace sdbusplus
14{
15namespace xyz
16{
17namespace openbmc_project
18{
19namespace Software
20{
Adriana Kobylak43699ca2018-10-17 14:56:29 -050021namespace Image
Gunnar Mills93c12d32017-05-10 13:11:53 -050022{
23namespace Error
24{
Adriana Kobylak2285fe02018-02-27 15:36:59 -060025struct UnTarFailure;
Gunnar Mills93c12d32017-05-10 13:11:53 -050026} // namespace Error
Adriana Kobylak43699ca2018-10-17 14:56:29 -050027} // namespace Image
Gunnar Mills93c12d32017-05-10 13:11:53 -050028} // namespace Software
29} // namespace openbmc_project
30} // namespace xyz
31} // namespace sdbusplus
32
33namespace sdbusplus
34{
35namespace xyz
36{
37namespace openbmc_project
38{
39namespace Software
40{
Adriana Kobylak43699ca2018-10-17 14:56:29 -050041namespace Image
Gunnar Mills93c12d32017-05-10 13:11:53 -050042{
43namespace Error
44{
Adriana Kobylak2285fe02018-02-27 15:36:59 -060045struct InternalFailure;
Gunnar Mills93c12d32017-05-10 13:11:53 -050046} // namespace Error
Adriana Kobylak43699ca2018-10-17 14:56:29 -050047} // namespace Image
Gunnar Mills93c12d32017-05-10 13:11:53 -050048} // namespace Software
49} // namespace openbmc_project
50} // namespace xyz
51} // namespace sdbusplus
52
53namespace sdbusplus
54{
55namespace xyz
56{
57namespace openbmc_project
58{
59namespace Software
60{
Adriana Kobylak43699ca2018-10-17 14:56:29 -050061namespace Image
Gunnar Mills93c12d32017-05-10 13:11:53 -050062{
63namespace Error
64{
Adriana Kobylak2285fe02018-02-27 15:36:59 -060065struct ManifestFileFailure;
Gunnar Mills93c12d32017-05-10 13:11:53 -050066} // namespace Error
Adriana Kobylak43699ca2018-10-17 14:56:29 -050067} // namespace Image
Gunnar Mills93c12d32017-05-10 13:11:53 -050068} // namespace Software
69} // namespace openbmc_project
70} // namespace xyz
71} // namespace sdbusplus
72
Gunnar Mills93c12d32017-05-10 13:11:53 -050073namespace phosphor
74{
75
76namespace logging
77{
78
79namespace xyz
80{
81namespace openbmc_project
82{
83namespace Software
84{
Adriana Kobylak43699ca2018-10-17 14:56:29 -050085namespace Image
Gunnar Mills93c12d32017-05-10 13:11:53 -050086{
87namespace _UnTarFailure
88{
89
90struct PATH
91{
92 static constexpr auto str = "PATH=%s";
93 static constexpr auto str_short = "PATH";
Adriana Kobylak2285fe02018-02-27 15:36:59 -060094 using type = std::tuple<std::decay_t<decltype(str)>, const char*>;
95 explicit constexpr PATH(const char* a) : _entry(entry(str, a)){};
Gunnar Mills93c12d32017-05-10 13:11:53 -050096 type _entry;
97};
98
Adriana Kobylak2285fe02018-02-27 15:36:59 -060099} // namespace _UnTarFailure
Gunnar Mills93c12d32017-05-10 13:11:53 -0500100
101struct UnTarFailure : public sdbusplus::exception_t
102{
Adriana Kobylak2285fe02018-02-27 15:36:59 -0600103 static constexpr auto errName =
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500104 "xyz.openbmc_project.Software.Image.UnTarFailure";
Gunnar Mills93c12d32017-05-10 13:11:53 -0500105 static constexpr auto errDesc = "An error occurred during untar.";
106 static constexpr auto L = level::ERR;
107 using PATH = _UnTarFailure::PATH;
108 using metadata_types = std::tuple<PATH>;
109
110 const char* name() const noexcept
111 {
112 return errName;
113 }
114
115 const char* description() const noexcept
116 {
117 return errDesc;
118 }
119
120 const char* what() const noexcept
121 {
122 return errName;
123 }
124};
125
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500126} // namespace Image
Gunnar Mills93c12d32017-05-10 13:11:53 -0500127} // namespace Software
128} // namespace openbmc_project
129} // namespace xyz
130
Gunnar Mills93c12d32017-05-10 13:11:53 -0500131namespace details
132{
133
134template <>
Adriana Kobylak2285fe02018-02-27 15:36:59 -0600135struct map_exception_type<
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500136 sdbusplus::xyz::openbmc_project::Software::Image::Error::UnTarFailure>
Gunnar Mills93c12d32017-05-10 13:11:53 -0500137{
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500138 using type = xyz::openbmc_project::Software::Image::UnTarFailure;
Gunnar Mills93c12d32017-05-10 13:11:53 -0500139};
Gunnar Millsfa34e022018-09-04 10:05:45 -0500140} // namespace details
Gunnar Mills93c12d32017-05-10 13:11:53 -0500141
142namespace xyz
143{
144namespace openbmc_project
145{
146namespace Software
147{
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500148namespace Image
Gunnar Mills93c12d32017-05-10 13:11:53 -0500149{
150namespace _ManifestFileFailure
151{
152
153struct PATH
154{
155 static constexpr auto str = "PATH=%s";
156 static constexpr auto str_short = "PATH";
Adriana Kobylak2285fe02018-02-27 15:36:59 -0600157 using type = std::tuple<std::decay_t<decltype(str)>, const char*>;
158 explicit constexpr PATH(const char* a) : _entry(entry(str, a)){};
Gunnar Mills93c12d32017-05-10 13:11:53 -0500159 type _entry;
160};
161
Adriana Kobylak2285fe02018-02-27 15:36:59 -0600162} // namespace _ManifestFileFailure
Gunnar Mills93c12d32017-05-10 13:11:53 -0500163
164struct ManifestFileFailure : public sdbusplus::exception_t
165{
Adriana Kobylak2285fe02018-02-27 15:36:59 -0600166 static constexpr auto errName =
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500167 "xyz.openbmc_project.Software.Image.ManifestFileFailure";
Gunnar Mills93c12d32017-05-10 13:11:53 -0500168 static constexpr auto errDesc = "An error when reading the Manifest file.";
169 static constexpr auto L = level::ERR;
170 using PATH = _ManifestFileFailure::PATH;
171 using metadata_types = std::tuple<PATH>;
172
173 const char* name() const noexcept
174 {
175 return errName;
176 }
177
178 const char* description() const noexcept
179 {
180 return errDesc;
181 }
182
183 const char* what() const noexcept
184 {
185 return errName;
186 }
187};
188
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500189} // namespace Image
Gunnar Mills93c12d32017-05-10 13:11:53 -0500190} // namespace Software
191} // namespace openbmc_project
192} // namespace xyz
193
Gunnar Mills93c12d32017-05-10 13:11:53 -0500194namespace details
195{
196
197template <>
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500198struct map_exception_type<sdbusplus::xyz::openbmc_project::Software::Image::
Adriana Kobylak2285fe02018-02-27 15:36:59 -0600199 Error::ManifestFileFailure>
Gunnar Mills93c12d32017-05-10 13:11:53 -0500200{
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500201 using type = xyz::openbmc_project::Software::Image::ManifestFileFailure;
Gunnar Mills93c12d32017-05-10 13:11:53 -0500202};
Gunnar Millsfa34e022018-09-04 10:05:45 -0500203} // namespace details
Gunnar Mills93c12d32017-05-10 13:11:53 -0500204
205namespace xyz
206{
207namespace openbmc_project
208{
209namespace Software
210{
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500211namespace Image
Gunnar Mills93c12d32017-05-10 13:11:53 -0500212{
213namespace _InternalFailure
214{
215
216struct FAIL
217{
218 static constexpr auto str = "FAIL=%s";
219 static constexpr auto str_short = "FAIL";
Adriana Kobylak2285fe02018-02-27 15:36:59 -0600220 using type = std::tuple<std::decay_t<decltype(str)>, const char*>;
221 explicit constexpr FAIL(const char* a) : _entry(entry(str, a)){};
Gunnar Mills93c12d32017-05-10 13:11:53 -0500222 type _entry;
223};
224
Adriana Kobylak2285fe02018-02-27 15:36:59 -0600225} // namespace _InternalFailure
Gunnar Mills93c12d32017-05-10 13:11:53 -0500226
227struct InternalFailure : public sdbusplus::exception_t
228{
Adriana Kobylak2285fe02018-02-27 15:36:59 -0600229 static constexpr auto errName =
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500230 "xyz.openbmc_project.Software.Image.InternalFailure";
Adriana Kobylak2285fe02018-02-27 15:36:59 -0600231 static constexpr auto errDesc =
232 "The operation failed internally during processing the image.";
Gunnar Mills93c12d32017-05-10 13:11:53 -0500233 static constexpr auto L = level::ERR;
234 using FAIL = _InternalFailure::FAIL;
235 using metadata_types = std::tuple<FAIL>;
236
237 const char* name() const noexcept
238 {
239 return errName;
240 }
241
242 const char* description() const noexcept
243 {
244 return errDesc;
245 }
246
247 const char* what() const noexcept
248 {
249 return errName;
250 }
251};
252
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500253} // namespace Image
Gunnar Mills93c12d32017-05-10 13:11:53 -0500254} // namespace Software
255} // namespace openbmc_project
256} // namespace xyz
257
Gunnar Mills93c12d32017-05-10 13:11:53 -0500258namespace details
259{
260
261template <>
Adriana Kobylak2285fe02018-02-27 15:36:59 -0600262struct map_exception_type<
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500263 sdbusplus::xyz::openbmc_project::Software::Image::Error::InternalFailure>
Gunnar Mills93c12d32017-05-10 13:11:53 -0500264{
Adriana Kobylak43699ca2018-10-17 14:56:29 -0500265 using type = xyz::openbmc_project::Software::Image::InternalFailure;
Gunnar Mills93c12d32017-05-10 13:11:53 -0500266};
Gunnar Millsfa34e022018-09-04 10:05:45 -0500267} // namespace details
Gunnar Mills93c12d32017-05-10 13:11:53 -0500268
Gunnar Mills93c12d32017-05-10 13:11:53 -0500269} // namespace logging
270
271} // namespace phosphor