| /* |
| * |
| * Copyright (c) 2022 Project CHIP Authors |
| * |
| * Licensed under the Apache License, Version 2.0 (the "License"); |
| * you may not use this file except in compliance with the License. |
| * You may obtain a copy of the License at |
| * |
| * http://www.apache.org/licenses/LICENSE-2.0 |
| * |
| * Unless required by applicable law or agreed to in writing, software |
| * distributed under the License is distributed on an "AS IS" BASIS, |
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| * See the License for the specific language governing permissions and |
| * limitations under the License. |
| */ |
| |
| // THIS FILE IS GENERATED BY ZAP |
| // This file is generated from clusters-Attributes.h.zapt |
| |
| #pragma once |
| |
| #include <app/ConcreteAttributePath.h> |
| #include <app/data-model/DecodableList.h> |
| #include <app/data-model/List.h> |
| #include <app/data-model/Nullable.h> |
| #include <app/util/basic-types.h> |
| #include <lib/core/TLV.h> |
| #include <lib/support/BitMask.h> |
| |
| #include <clusters/shared/Attributes.h> |
| #include <clusters/shared/Enums.h> |
| #include <clusters/shared/Structs.h> |
| |
| #include <clusters/CommodityTariff/AttributeIds.h> |
| #include <clusters/CommodityTariff/ClusterId.h> |
| #include <clusters/CommodityTariff/Enums.h> |
| #include <clusters/CommodityTariff/Structs.h> |
| |
| namespace chip { |
| namespace app { |
| namespace Clusters { |
| namespace CommodityTariff { |
| namespace Attributes { |
| |
| namespace TariffInfo { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::TariffInformationStruct::Type>; |
| using DecodableType = |
| chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::TariffInformationStruct::DecodableType>; |
| using DecodableArgType = const chip::app::DataModel::Nullable< |
| chip::app::Clusters::CommodityTariff::Structs::TariffInformationStruct::DecodableType> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::TariffInfo::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace TariffInfo |
| namespace TariffUnit { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable<chip::app::Clusters::Globals::TariffUnitEnum>; |
| using DecodableType = chip::app::DataModel::Nullable<chip::app::Clusters::Globals::TariffUnitEnum>; |
| using DecodableArgType = const chip::app::DataModel::Nullable<chip::app::Clusters::Globals::TariffUnitEnum> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::TariffUnit::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace TariffUnit |
| namespace StartDate { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable<uint32_t>; |
| using DecodableType = chip::app::DataModel::Nullable<uint32_t>; |
| using DecodableArgType = const chip::app::DataModel::Nullable<uint32_t> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::StartDate::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace StartDate |
| namespace DayEntries { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable< |
| chip::app::DataModel::List<const chip::app::Clusters::CommodityTariff::Structs::DayEntryStruct::Type>>; |
| using DecodableType = chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::DayEntryStruct::DecodableType>>; |
| using DecodableArgType = const chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::DayEntryStruct::DecodableType>> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::DayEntries::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace DayEntries |
| namespace DayPatterns { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable< |
| chip::app::DataModel::List<const chip::app::Clusters::CommodityTariff::Structs::DayPatternStruct::Type>>; |
| using DecodableType = chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::DayPatternStruct::DecodableType>>; |
| using DecodableArgType = const chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::DayPatternStruct::DecodableType>> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::DayPatterns::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace DayPatterns |
| namespace CalendarPeriods { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable< |
| chip::app::DataModel::List<const chip::app::Clusters::CommodityTariff::Structs::CalendarPeriodStruct::Type>>; |
| using DecodableType = chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::CalendarPeriodStruct::DecodableType>>; |
| using DecodableArgType = const chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::CalendarPeriodStruct::DecodableType>> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::CalendarPeriods::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace CalendarPeriods |
| namespace IndividualDays { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable< |
| chip::app::DataModel::List<const chip::app::Clusters::CommodityTariff::Structs::DayStruct::Type>>; |
| using DecodableType = chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::DayStruct::DecodableType>>; |
| using DecodableArgType = const chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::DayStruct::DecodableType>> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::IndividualDays::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace IndividualDays |
| namespace CurrentDay { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::DayStruct::Type>; |
| using DecodableType = chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::DayStruct::DecodableType>; |
| using DecodableArgType = |
| const chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::DayStruct::DecodableType> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::CurrentDay::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace CurrentDay |
| namespace NextDay { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::DayStruct::Type>; |
| using DecodableType = chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::DayStruct::DecodableType>; |
| using DecodableArgType = |
| const chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::DayStruct::DecodableType> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::NextDay::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace NextDay |
| namespace CurrentDayEntry { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::DayEntryStruct::Type>; |
| using DecodableType = |
| chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::DayEntryStruct::DecodableType>; |
| using DecodableArgType = |
| const chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::DayEntryStruct::DecodableType> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::CurrentDayEntry::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace CurrentDayEntry |
| namespace CurrentDayEntryDate { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable<uint32_t>; |
| using DecodableType = chip::app::DataModel::Nullable<uint32_t>; |
| using DecodableArgType = const chip::app::DataModel::Nullable<uint32_t> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::CurrentDayEntryDate::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace CurrentDayEntryDate |
| namespace NextDayEntry { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::DayEntryStruct::Type>; |
| using DecodableType = |
| chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::DayEntryStruct::DecodableType>; |
| using DecodableArgType = |
| const chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::Structs::DayEntryStruct::DecodableType> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::NextDayEntry::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace NextDayEntry |
| namespace NextDayEntryDate { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable<uint32_t>; |
| using DecodableType = chip::app::DataModel::Nullable<uint32_t>; |
| using DecodableArgType = const chip::app::DataModel::Nullable<uint32_t> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::NextDayEntryDate::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace NextDayEntryDate |
| namespace TariffComponents { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable< |
| chip::app::DataModel::List<const chip::app::Clusters::CommodityTariff::Structs::TariffComponentStruct::Type>>; |
| using DecodableType = chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::TariffComponentStruct::DecodableType>>; |
| using DecodableArgType = const chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::TariffComponentStruct::DecodableType>> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::TariffComponents::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace TariffComponents |
| namespace TariffPeriods { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable< |
| chip::app::DataModel::List<const chip::app::Clusters::CommodityTariff::Structs::TariffPeriodStruct::Type>>; |
| using DecodableType = chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::TariffPeriodStruct::DecodableType>>; |
| using DecodableArgType = const chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::TariffPeriodStruct::DecodableType>> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::TariffPeriods::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace TariffPeriods |
| namespace CurrentTariffComponents { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable< |
| chip::app::DataModel::List<const chip::app::Clusters::CommodityTariff::Structs::TariffComponentStruct::Type>>; |
| using DecodableType = chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::TariffComponentStruct::DecodableType>>; |
| using DecodableArgType = const chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::TariffComponentStruct::DecodableType>> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::CurrentTariffComponents::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace CurrentTariffComponents |
| namespace NextTariffComponents { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable< |
| chip::app::DataModel::List<const chip::app::Clusters::CommodityTariff::Structs::TariffComponentStruct::Type>>; |
| using DecodableType = chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::TariffComponentStruct::DecodableType>>; |
| using DecodableArgType = const chip::app::DataModel::Nullable< |
| chip::app::DataModel::DecodableList<chip::app::Clusters::CommodityTariff::Structs::TariffComponentStruct::DecodableType>> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::NextTariffComponents::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace NextTariffComponents |
| namespace DefaultRandomizationOffset { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable<int16_t>; |
| using DecodableType = chip::app::DataModel::Nullable<int16_t>; |
| using DecodableArgType = const chip::app::DataModel::Nullable<int16_t> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::DefaultRandomizationOffset::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace DefaultRandomizationOffset |
| namespace DefaultRandomizationType { |
| struct TypeInfo |
| { |
| using Type = chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::DayEntryRandomizationTypeEnum>; |
| using DecodableType = chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::DayEntryRandomizationTypeEnum>; |
| using DecodableArgType = |
| const chip::app::DataModel::Nullable<chip::app::Clusters::CommodityTariff::DayEntryRandomizationTypeEnum> &; |
| |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| static constexpr AttributeId GetAttributeId() { return Attributes::DefaultRandomizationType::Id; } |
| static constexpr bool MustUseTimedWrite() { return false; } |
| }; |
| } // namespace DefaultRandomizationType |
| namespace GeneratedCommandList { |
| struct TypeInfo : public Clusters::Globals::Attributes::GeneratedCommandList::TypeInfo |
| { |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| }; |
| } // namespace GeneratedCommandList |
| namespace AcceptedCommandList { |
| struct TypeInfo : public Clusters::Globals::Attributes::AcceptedCommandList::TypeInfo |
| { |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| }; |
| } // namespace AcceptedCommandList |
| namespace AttributeList { |
| struct TypeInfo : public Clusters::Globals::Attributes::AttributeList::TypeInfo |
| { |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| }; |
| } // namespace AttributeList |
| namespace FeatureMap { |
| struct TypeInfo : public Clusters::Globals::Attributes::FeatureMap::TypeInfo |
| { |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| }; |
| } // namespace FeatureMap |
| namespace ClusterRevision { |
| struct TypeInfo : public Clusters::Globals::Attributes::ClusterRevision::TypeInfo |
| { |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| }; |
| } // namespace ClusterRevision |
| |
| struct TypeInfo |
| { |
| struct DecodableType |
| { |
| static constexpr ClusterId GetClusterId() { return Clusters::CommodityTariff::Id; } |
| |
| CHIP_ERROR Decode(TLV::TLVReader & reader, const ConcreteAttributePath & path); |
| |
| Attributes::TariffInfo::TypeInfo::DecodableType tariffInfo; |
| Attributes::TariffUnit::TypeInfo::DecodableType tariffUnit; |
| Attributes::StartDate::TypeInfo::DecodableType startDate; |
| Attributes::DayEntries::TypeInfo::DecodableType dayEntries; |
| Attributes::DayPatterns::TypeInfo::DecodableType dayPatterns; |
| Attributes::CalendarPeriods::TypeInfo::DecodableType calendarPeriods; |
| Attributes::IndividualDays::TypeInfo::DecodableType individualDays; |
| Attributes::CurrentDay::TypeInfo::DecodableType currentDay; |
| Attributes::NextDay::TypeInfo::DecodableType nextDay; |
| Attributes::CurrentDayEntry::TypeInfo::DecodableType currentDayEntry; |
| Attributes::CurrentDayEntryDate::TypeInfo::DecodableType currentDayEntryDate; |
| Attributes::NextDayEntry::TypeInfo::DecodableType nextDayEntry; |
| Attributes::NextDayEntryDate::TypeInfo::DecodableType nextDayEntryDate; |
| Attributes::TariffComponents::TypeInfo::DecodableType tariffComponents; |
| Attributes::TariffPeriods::TypeInfo::DecodableType tariffPeriods; |
| Attributes::CurrentTariffComponents::TypeInfo::DecodableType currentTariffComponents; |
| Attributes::NextTariffComponents::TypeInfo::DecodableType nextTariffComponents; |
| Attributes::DefaultRandomizationOffset::TypeInfo::DecodableType defaultRandomizationOffset; |
| Attributes::DefaultRandomizationType::TypeInfo::DecodableType defaultRandomizationType; |
| Attributes::GeneratedCommandList::TypeInfo::DecodableType generatedCommandList; |
| Attributes::AcceptedCommandList::TypeInfo::DecodableType acceptedCommandList; |
| Attributes::AttributeList::TypeInfo::DecodableType attributeList; |
| Attributes::FeatureMap::TypeInfo::DecodableType featureMap = static_cast<uint32_t>(0); |
| Attributes::ClusterRevision::TypeInfo::DecodableType clusterRevision = static_cast<uint16_t>(0); |
| }; |
| }; |
| } // namespace Attributes |
| } // namespace CommodityTariff |
| } // namespace Clusters |
| } // namespace app |
| } // namespace chip |