/src/connectedhomeip/zzz_generated/app-common/clusters/MicrowaveOvenControl/Commands.h
Line | Count | Source (jump to first uncovered line) |
1 | | /* |
2 | | * |
3 | | * Copyright (c) 2022 Project CHIP Authors |
4 | | * |
5 | | * Licensed under the Apache License, Version 2.0 (the "License"); |
6 | | * you may not use this file except in compliance with the License. |
7 | | * You may obtain a copy of the License at |
8 | | * |
9 | | * http://www.apache.org/licenses/LICENSE-2.0 |
10 | | * |
11 | | * Unless required by applicable law or agreed to in writing, software |
12 | | * distributed under the License is distributed on an "AS IS" BASIS, |
13 | | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
14 | | * See the License for the specific language governing permissions and |
15 | | * limitations under the License. |
16 | | */ |
17 | | |
18 | | // THIS FILE IS GENERATED BY ZAP |
19 | | // This file is generated from clusters-Commands.h.zapt |
20 | | |
21 | | #pragma once |
22 | | |
23 | | #include <app/data-model/DecodableList.h> |
24 | | #include <app/data-model/Encode.h> |
25 | | #include <app/data-model/List.h> |
26 | | #include <app/data-model/NullObject.h> |
27 | | #include <app/data-model/Nullable.h> |
28 | | #include <lib/core/DataModelTypes.h> |
29 | | #include <lib/core/Optional.h> |
30 | | #include <lib/core/TLV.h> |
31 | | #include <lib/support/BitMask.h> |
32 | | |
33 | | #include <clusters/shared/Enums.h> |
34 | | #include <clusters/shared/Structs.h> |
35 | | |
36 | | #include <clusters/MicrowaveOvenControl/ClusterId.h> |
37 | | #include <clusters/MicrowaveOvenControl/CommandIds.h> |
38 | | #include <clusters/MicrowaveOvenControl/Enums.h> |
39 | | #include <clusters/MicrowaveOvenControl/Structs.h> |
40 | | |
41 | | #include <cstdint> |
42 | | |
43 | | namespace chip { |
44 | | namespace app { |
45 | | namespace Clusters { |
46 | | namespace MicrowaveOvenControl { |
47 | | namespace Commands { |
48 | | // Forward-declarations so we can reference these later. |
49 | | |
50 | | namespace SetCookingParameters { |
51 | | struct Type; |
52 | | struct DecodableType; |
53 | | } // namespace SetCookingParameters |
54 | | |
55 | | namespace AddMoreTime { |
56 | | struct Type; |
57 | | struct DecodableType; |
58 | | } // namespace AddMoreTime |
59 | | |
60 | | } // namespace Commands |
61 | | |
62 | | namespace Commands { |
63 | | namespace SetCookingParameters { |
64 | | enum class Fields : uint8_t |
65 | | { |
66 | | kCookMode = 0, |
67 | | kCookTime = 1, |
68 | | kPowerSetting = 2, |
69 | | kWattSettingIndex = 3, |
70 | | kStartAfterSetting = 4, |
71 | | }; |
72 | | |
73 | | struct Type |
74 | | { |
75 | | public: |
76 | | // Use GetCommandId instead of commandId directly to avoid naming conflict with CommandIdentification in ExecutionOfACommand |
77 | 0 | static constexpr CommandId GetCommandId() { return Commands::SetCookingParameters::Id; } |
78 | 0 | static constexpr ClusterId GetClusterId() { return Clusters::MicrowaveOvenControl::Id; } |
79 | | |
80 | | Optional<uint8_t> cookMode; |
81 | | Optional<uint32_t> cookTime; |
82 | | Optional<uint8_t> powerSetting; |
83 | | Optional<uint8_t> wattSettingIndex; |
84 | | Optional<bool> startAfterSetting; |
85 | | |
86 | | CHIP_ERROR Encode(TLV::TLVWriter & aWriter, TLV::Tag aTag) const; |
87 | | |
88 | | using ResponseType = DataModel::NullObjectType; |
89 | | |
90 | 0 | static constexpr bool MustUseTimedInvoke() { return false; } |
91 | | }; |
92 | | |
93 | | struct DecodableType |
94 | | { |
95 | | public: |
96 | 0 | static constexpr CommandId GetCommandId() { return Commands::SetCookingParameters::Id; } |
97 | 0 | static constexpr ClusterId GetClusterId() { return Clusters::MicrowaveOvenControl::Id; } |
98 | | static constexpr bool kIsFabricScoped = false; |
99 | | |
100 | | Optional<uint8_t> cookMode; |
101 | | Optional<uint32_t> cookTime; |
102 | | Optional<uint8_t> powerSetting; |
103 | | Optional<uint8_t> wattSettingIndex; |
104 | | Optional<bool> startAfterSetting; |
105 | | |
106 | | CHIP_ERROR Decode(TLV::TLVReader & reader); |
107 | | }; |
108 | | }; // namespace SetCookingParameters |
109 | | namespace AddMoreTime { |
110 | | enum class Fields : uint8_t |
111 | | { |
112 | | kTimeToAdd = 0, |
113 | | }; |
114 | | |
115 | | struct Type |
116 | | { |
117 | | public: |
118 | | // Use GetCommandId instead of commandId directly to avoid naming conflict with CommandIdentification in ExecutionOfACommand |
119 | 0 | static constexpr CommandId GetCommandId() { return Commands::AddMoreTime::Id; } |
120 | 0 | static constexpr ClusterId GetClusterId() { return Clusters::MicrowaveOvenControl::Id; } |
121 | | |
122 | | uint32_t timeToAdd = static_cast<uint32_t>(0); |
123 | | |
124 | | CHIP_ERROR Encode(TLV::TLVWriter & aWriter, TLV::Tag aTag) const; |
125 | | |
126 | | using ResponseType = DataModel::NullObjectType; |
127 | | |
128 | 0 | static constexpr bool MustUseTimedInvoke() { return false; } |
129 | | }; |
130 | | |
131 | | struct DecodableType |
132 | | { |
133 | | public: |
134 | 0 | static constexpr CommandId GetCommandId() { return Commands::AddMoreTime::Id; } |
135 | 0 | static constexpr ClusterId GetClusterId() { return Clusters::MicrowaveOvenControl::Id; } |
136 | | static constexpr bool kIsFabricScoped = false; |
137 | | |
138 | | uint32_t timeToAdd = static_cast<uint32_t>(0); |
139 | | |
140 | | CHIP_ERROR Decode(TLV::TLVReader & reader); |
141 | | }; |
142 | | }; // namespace AddMoreTime |
143 | | } // namespace Commands |
144 | | } // namespace MicrowaveOvenControl |
145 | | } // namespace Clusters |
146 | | } // namespace app |
147 | | } // namespace chip |