Coverage Report

Created: 2026-03-27 06:51

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/connectedhomeip/zzz_generated/app-common/clusters/CommodityTariff/Commands.h
Line
Count
Source
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/CommodityTariff/ClusterId.h>
37
#include <clusters/CommodityTariff/CommandIds.h>
38
#include <clusters/CommodityTariff/Enums.h>
39
#include <clusters/CommodityTariff/Structs.h>
40
41
#include <cstdint>
42
43
namespace chip {
44
namespace app {
45
namespace Clusters {
46
namespace CommodityTariff {
47
namespace Commands {
48
// Forward-declarations so we can reference these later.
49
50
namespace GetTariffComponent {
51
struct Type;
52
struct DecodableType;
53
} // namespace GetTariffComponent
54
55
namespace GetTariffComponentResponse {
56
struct Type;
57
struct DecodableType;
58
} // namespace GetTariffComponentResponse
59
60
namespace GetDayEntry {
61
struct Type;
62
struct DecodableType;
63
} // namespace GetDayEntry
64
65
namespace GetDayEntryResponse {
66
struct Type;
67
struct DecodableType;
68
} // namespace GetDayEntryResponse
69
70
} // namespace Commands
71
72
namespace Commands {
73
namespace GetTariffComponent {
74
enum class Fields : uint8_t
75
{
76
    kTariffComponentID = 0,
77
};
78
79
struct Type
80
{
81
public:
82
    // Use GetCommandId instead of commandId directly to avoid naming conflict with CommandIdentification in ExecutionOfACommand
83
0
    static constexpr CommandId GetCommandId() { return Commands::GetTariffComponent::Id; }
84
0
    static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; }
85
86
    uint32_t tariffComponentID = static_cast<uint32_t>(0);
87
88
    CHIP_ERROR Encode(TLV::TLVWriter & aWriter, TLV::Tag aTag) const;
89
90
    using ResponseType = Clusters::CommodityTariff::Commands::GetTariffComponentResponse::DecodableType;
91
92
0
    static constexpr bool MustUseTimedInvoke() { return false; }
93
};
94
95
struct DecodableType
96
{
97
public:
98
0
    static constexpr CommandId GetCommandId() { return Commands::GetTariffComponent::Id; }
99
0
    static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; }
100
    static constexpr bool kIsFabricScoped = false;
101
102
    uint32_t tariffComponentID = static_cast<uint32_t>(0);
103
104
    CHIP_ERROR Decode(TLV::TLVReader & reader);
105
};
106
}; // namespace GetTariffComponent
107
namespace GetTariffComponentResponse {
108
enum class Fields : uint8_t
109
{
110
    kLabel           = 0,
111
    kDayEntryIDs     = 1,
112
    kTariffComponent = 2,
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::GetTariffComponentResponse::Id; }
120
0
    static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; }
121
122
    DataModel::Nullable<chip::CharSpan> label;
123
    DataModel::List<const uint32_t> dayEntryIDs;
124
    Structs::TariffComponentStruct::Type tariffComponent;
125
126
    CHIP_ERROR Encode(DataModel::FabricAwareTLVWriter & aWriter, TLV::Tag aTag) const;
127
128
    using ResponseType = DataModel::NullObjectType;
129
130
0
    static constexpr bool MustUseTimedInvoke() { return false; }
131
};
132
133
struct DecodableType
134
{
135
public:
136
0
    static constexpr CommandId GetCommandId() { return Commands::GetTariffComponentResponse::Id; }
137
0
    static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; }
138
139
    DataModel::Nullable<chip::CharSpan> label;
140
    DataModel::DecodableList<uint32_t> dayEntryIDs;
141
    Structs::TariffComponentStruct::DecodableType tariffComponent;
142
143
    CHIP_ERROR Decode(TLV::TLVReader & reader);
144
};
145
}; // namespace GetTariffComponentResponse
146
namespace GetDayEntry {
147
enum class Fields : uint8_t
148
{
149
    kDayEntryID = 0,
150
};
151
152
struct Type
153
{
154
public:
155
    // Use GetCommandId instead of commandId directly to avoid naming conflict with CommandIdentification in ExecutionOfACommand
156
0
    static constexpr CommandId GetCommandId() { return Commands::GetDayEntry::Id; }
157
0
    static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; }
158
159
    uint32_t dayEntryID = static_cast<uint32_t>(0);
160
161
    CHIP_ERROR Encode(TLV::TLVWriter & aWriter, TLV::Tag aTag) const;
162
163
    using ResponseType = Clusters::CommodityTariff::Commands::GetDayEntryResponse::DecodableType;
164
165
0
    static constexpr bool MustUseTimedInvoke() { return false; }
166
};
167
168
struct DecodableType
169
{
170
public:
171
0
    static constexpr CommandId GetCommandId() { return Commands::GetDayEntry::Id; }
172
0
    static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; }
173
    static constexpr bool kIsFabricScoped = false;
174
175
    uint32_t dayEntryID = static_cast<uint32_t>(0);
176
177
    CHIP_ERROR Decode(TLV::TLVReader & reader);
178
};
179
}; // namespace GetDayEntry
180
namespace GetDayEntryResponse {
181
enum class Fields : uint8_t
182
{
183
    kDayEntry = 0,
184
};
185
186
struct Type
187
{
188
public:
189
    // Use GetCommandId instead of commandId directly to avoid naming conflict with CommandIdentification in ExecutionOfACommand
190
0
    static constexpr CommandId GetCommandId() { return Commands::GetDayEntryResponse::Id; }
191
0
    static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; }
192
193
    Structs::DayEntryStruct::Type dayEntry;
194
195
    CHIP_ERROR Encode(DataModel::FabricAwareTLVWriter & aWriter, TLV::Tag aTag) const;
196
197
    using ResponseType = DataModel::NullObjectType;
198
199
0
    static constexpr bool MustUseTimedInvoke() { return false; }
200
};
201
202
struct DecodableType
203
{
204
public:
205
0
    static constexpr CommandId GetCommandId() { return Commands::GetDayEntryResponse::Id; }
206
0
    static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; }
207
208
    Structs::DayEntryStruct::DecodableType dayEntry;
209
210
    CHIP_ERROR Decode(TLV::TLVReader & reader);
211
};
212
}; // namespace GetDayEntryResponse
213
} // namespace Commands
214
} // namespace CommodityTariff
215
} // namespace Clusters
216
} // namespace app
217
} // namespace chip