blob: 0f1fa97ca163c06bced6252479ca0145ac1276ab [file]
/*
*
* 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.ipp.zapt
#include <clusters/SmokeCoAlarm/Attributes.h>
#include <app/data-model/Decode.h>
#include <app/data-model/WrappedStructEncoder.h>
namespace chip {
namespace app {
namespace Clusters {
namespace SmokeCoAlarm {
namespace Attributes {
CHIP_ERROR TypeInfo::DecodableType::Decode(TLV::TLVReader & reader, const ConcreteAttributePath & path)
{
switch (path.mAttributeId)
{
case Attributes::ExpressedState::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, expressedState);
case Attributes::SmokeState::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, smokeState);
case Attributes::COState::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, COState);
case Attributes::BatteryAlert::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, batteryAlert);
case Attributes::DeviceMuted::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, deviceMuted);
case Attributes::TestInProgress::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, testInProgress);
case Attributes::HardwareFaultAlert::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, hardwareFaultAlert);
case Attributes::EndOfServiceAlert::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, endOfServiceAlert);
case Attributes::InterconnectSmokeAlarm::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, interconnectSmokeAlarm);
case Attributes::InterconnectCOAlarm::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, interconnectCOAlarm);
case Attributes::ContaminationState::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, contaminationState);
case Attributes::SmokeSensitivityLevel::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, smokeSensitivityLevel);
case Attributes::ExpiryDate::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, expiryDate);
case Attributes::GeneratedCommandList::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, generatedCommandList);
case Attributes::AcceptedCommandList::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, acceptedCommandList);
case Attributes::AttributeList::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, attributeList);
case Attributes::FeatureMap::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, featureMap);
case Attributes::ClusterRevision::TypeInfo::GetAttributeId():
return DataModel::Decode(reader, clusterRevision);
default:
return CHIP_NO_ERROR;
}
}
} // namespace Attributes
} // namespace SmokeCoAlarm
} // namespace Clusters
} // namespace app
} // namespace chip