/*
 *
 *    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/GeneralDiagnostics/AttributeIds.h>
#include <clusters/GeneralDiagnostics/ClusterId.h>
#include <clusters/GeneralDiagnostics/Enums.h>
#include <clusters/GeneralDiagnostics/Structs.h>

namespace chip {
namespace app {
namespace Clusters {
namespace GeneralDiagnostics {
namespace Attributes {

namespace NetworkInterfaces {
struct TypeInfo {
  using Type =
      chip::app::DataModel::List<const chip::app::Clusters::GeneralDiagnostics::
                                     Structs::NetworkInterface::Type>;
  using DecodableType = chip::app::DataModel::DecodableList<
      chip::app::Clusters::GeneralDiagnostics::Structs::NetworkInterface::
          DecodableType>;
  using DecodableArgType = const chip::app::DataModel::DecodableList<
      chip::app::Clusters::GeneralDiagnostics::Structs::NetworkInterface::
          DecodableType> &;

  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
  static constexpr AttributeId GetAttributeId() {
    return Attributes::NetworkInterfaces::Id;
  }
  static constexpr bool MustUseTimedWrite() { return false; }
};
} // namespace NetworkInterfaces
namespace RebootCount {
struct TypeInfo {
  using Type = uint16_t;
  using DecodableType = uint16_t;
  using DecodableArgType = uint16_t;

  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
  static constexpr AttributeId GetAttributeId() {
    return Attributes::RebootCount::Id;
  }
  static constexpr bool MustUseTimedWrite() { return false; }
};
} // namespace RebootCount
namespace UpTime {
struct TypeInfo {
  using Type = uint64_t;
  using DecodableType = uint64_t;
  using DecodableArgType = uint64_t;

  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
  static constexpr AttributeId GetAttributeId() {
    return Attributes::UpTime::Id;
  }
  static constexpr bool MustUseTimedWrite() { return false; }
};
} // namespace UpTime
namespace TotalOperationalHours {
struct TypeInfo {
  using Type = uint32_t;
  using DecodableType = uint32_t;
  using DecodableArgType = uint32_t;

  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
  static constexpr AttributeId GetAttributeId() {
    return Attributes::TotalOperationalHours::Id;
  }
  static constexpr bool MustUseTimedWrite() { return false; }
};
} // namespace TotalOperationalHours
namespace BootReason {
struct TypeInfo {
  using Type = chip::app::Clusters::GeneralDiagnostics::BootReasonEnum;
  using DecodableType = chip::app::Clusters::GeneralDiagnostics::BootReasonEnum;
  using DecodableArgType =
      chip::app::Clusters::GeneralDiagnostics::BootReasonEnum;

  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
  static constexpr AttributeId GetAttributeId() {
    return Attributes::BootReason::Id;
  }
  static constexpr bool MustUseTimedWrite() { return false; }
};
} // namespace BootReason
namespace ActiveHardwareFaults {
struct TypeInfo {
  using Type = chip::app::DataModel::List<
      const chip::app::Clusters::GeneralDiagnostics::HardwareFaultEnum>;
  using DecodableType = chip::app::DataModel::DecodableList<
      chip::app::Clusters::GeneralDiagnostics::HardwareFaultEnum>;
  using DecodableArgType = const chip::app::DataModel::DecodableList<
      chip::app::Clusters::GeneralDiagnostics::HardwareFaultEnum> &;

  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
  static constexpr AttributeId GetAttributeId() {
    return Attributes::ActiveHardwareFaults::Id;
  }
  static constexpr bool MustUseTimedWrite() { return false; }
};
} // namespace ActiveHardwareFaults
namespace ActiveRadioFaults {
struct TypeInfo {
  using Type = chip::app::DataModel::List<
      const chip::app::Clusters::GeneralDiagnostics::RadioFaultEnum>;
  using DecodableType = chip::app::DataModel::DecodableList<
      chip::app::Clusters::GeneralDiagnostics::RadioFaultEnum>;
  using DecodableArgType = const chip::app::DataModel::DecodableList<
      chip::app::Clusters::GeneralDiagnostics::RadioFaultEnum> &;

  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
  static constexpr AttributeId GetAttributeId() {
    return Attributes::ActiveRadioFaults::Id;
  }
  static constexpr bool MustUseTimedWrite() { return false; }
};
} // namespace ActiveRadioFaults
namespace ActiveNetworkFaults {
struct TypeInfo {
  using Type = chip::app::DataModel::List<
      const chip::app::Clusters::GeneralDiagnostics::NetworkFaultEnum>;
  using DecodableType = chip::app::DataModel::DecodableList<
      chip::app::Clusters::GeneralDiagnostics::NetworkFaultEnum>;
  using DecodableArgType = const chip::app::DataModel::DecodableList<
      chip::app::Clusters::GeneralDiagnostics::NetworkFaultEnum> &;

  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
  static constexpr AttributeId GetAttributeId() {
    return Attributes::ActiveNetworkFaults::Id;
  }
  static constexpr bool MustUseTimedWrite() { return false; }
};
} // namespace ActiveNetworkFaults
namespace TestEventTriggersEnabled {
struct TypeInfo {
  using Type = bool;
  using DecodableType = bool;
  using DecodableArgType = bool;

  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
  static constexpr AttributeId GetAttributeId() {
    return Attributes::TestEventTriggersEnabled::Id;
  }
  static constexpr bool MustUseTimedWrite() { return false; }
};
} // namespace TestEventTriggersEnabled
namespace GeneratedCommandList {
struct TypeInfo
    : public Clusters::Globals::Attributes::GeneratedCommandList::TypeInfo {
  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
};
} // namespace GeneratedCommandList
namespace AcceptedCommandList {
struct TypeInfo
    : public Clusters::Globals::Attributes::AcceptedCommandList::TypeInfo {
  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
};
} // namespace AcceptedCommandList
namespace AttributeList {
struct TypeInfo
    : public Clusters::Globals::Attributes::AttributeList::TypeInfo {
  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
};
} // namespace AttributeList
namespace FeatureMap {
struct TypeInfo : public Clusters::Globals::Attributes::FeatureMap::TypeInfo {
  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
};
} // namespace FeatureMap
namespace ClusterRevision {
struct TypeInfo
    : public Clusters::Globals::Attributes::ClusterRevision::TypeInfo {
  static constexpr ClusterId GetClusterId() {
    return Clusters::GeneralDiagnostics::Id;
  }
};
} // namespace ClusterRevision

struct TypeInfo {
  struct DecodableType {
    static constexpr ClusterId GetClusterId() {
      return Clusters::GeneralDiagnostics::Id;
    }

    CHIP_ERROR Decode(TLV::TLVReader &reader,
                      const ConcreteAttributePath &path);

    Attributes::NetworkInterfaces::TypeInfo::DecodableType networkInterfaces;
    Attributes::RebootCount::TypeInfo::DecodableType rebootCount =
        static_cast<uint16_t>(0);
    Attributes::UpTime::TypeInfo::DecodableType upTime =
        static_cast<uint64_t>(0);
    Attributes::TotalOperationalHours::TypeInfo::DecodableType
        totalOperationalHours = static_cast<uint32_t>(0);
    Attributes::BootReason::TypeInfo::DecodableType bootReason =
        static_cast<chip::app::Clusters::GeneralDiagnostics::BootReasonEnum>(0);
    Attributes::ActiveHardwareFaults::TypeInfo::DecodableType
        activeHardwareFaults;
    Attributes::ActiveRadioFaults::TypeInfo::DecodableType activeRadioFaults;
    Attributes::ActiveNetworkFaults::TypeInfo::DecodableType
        activeNetworkFaults;
    Attributes::TestEventTriggersEnabled::TypeInfo::DecodableType
        testEventTriggersEnabled = static_cast<bool>(0);
    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 GeneralDiagnostics
} // namespace Clusters
} // namespace app
} // namespace chip
