Skip to content

Commit 2991c76

Browse files
Refactor Resource Monitoring to Separate out The Delegate functionality (project-chip#28725)
* Move Constructors And Destructors To The Top Of The Instance * Add Delegate Instead Of Just The Instance Following the Mode Base Cluster, to make it more similar. * Use New Delegate In Resource-Monitoring-App Example * Rename "instances" Folder to "delegates" also adjust include paths and BUILD.gn paths * Use New Resource Monitoring Delegate In All-Cluster-App Example * Fix Typo * Rename "resource-monitoring-instances.h/cpp" To "resource-monitoring-delegates.h/cpp" * Add Shutdown Methods For All-Cluster-App * Fix Some Comments And Logs * Restyled by whitespace * Restyled by clang-format * Fix Build Error From Merge * Fix Build Error * Add Missing Destructor needs to unregister Command Handler and Attribute Accesser * Restyled by whitespace * Restyled by clang-format * Fix Spelling * Remove `isValidAliascluster` method it should be the SDK user's responsibility to select the correct cluster ID and that it also requires the maintenance of a global list. * Make Instance A Friend Of Delegate -> make mInstance private with private setter and protected getter * Restyled by whitespace * Restyled by clang-format * Fix Build Error --------- Co-authored-by: Restyled.io <commits@restyled.io>
1 parent 2dc43d7 commit 2991c76

30 files changed

+421
-334
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
/*
2+
*
3+
* Copyright (c) 2023 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+
#include <app-common/zap-generated/ids/Attributes.h>
19+
#include <app-common/zap-generated/ids/Clusters.h>
20+
#include <app/clusters/resource-monitoring-server/resource-monitoring-cluster-objects.h>
21+
#include <app/clusters/resource-monitoring-server/resource-monitoring-server.h>
22+
23+
namespace chip {
24+
namespace app {
25+
namespace Clusters {
26+
27+
namespace ActivatedCarbonFilterMonitoring {
28+
/// This is an application level Delegate to handle ActivatedCarbonfilterMonitoringDelegate commands according to the specific
29+
/// business logic.
30+
class ActivatedCarbonFilterMonitoringDelegate : public ResourceMonitoring::Delegate
31+
{
32+
private:
33+
CHIP_ERROR Init() override;
34+
chip::Protocols::InteractionModel::Status PreResetCondition() override;
35+
chip::Protocols::InteractionModel::Status PostResetCondition() override;
36+
37+
public:
38+
~ActivatedCarbonFilterMonitoringDelegate() override = default;
39+
};
40+
41+
void Shutdown();
42+
43+
} // namespace ActivatedCarbonFilterMonitoring
44+
45+
namespace HepaFilterMonitoring {
46+
/// This is an application level Delegate to handle HepaFilterMonitoringDelegate commands according to the specific business logic.
47+
class HepaFilterMonitoringDelegate : public ResourceMonitoring::Delegate
48+
{
49+
private:
50+
CHIP_ERROR Init() override;
51+
chip::Protocols::InteractionModel::Status PreResetCondition() override;
52+
chip::Protocols::InteractionModel::Status PostResetCondition() override;
53+
54+
public:
55+
~HepaFilterMonitoringDelegate() override = default;
56+
};
57+
58+
class ImmutableReplacementProductListManager : public ResourceMonitoring::ReplacementProductListManager
59+
{
60+
public:
61+
CHIP_ERROR
62+
Next(chip::app::Clusters::ResourceMonitoring::ReplacementProductStruct & item) override;
63+
};
64+
65+
void Shutdown();
66+
67+
} // namespace HepaFilterMonitoring
68+
69+
} // namespace Clusters
70+
} // namespace app
71+
} // namespace chip

examples/all-clusters-app/all-clusters-common/src/resource-monitoring-instances.cpp examples/all-clusters-app/all-clusters-common/src/resource-monitoring-delegates.cpp

+70-30
Original file line numberDiff line numberDiff line change
@@ -19,77 +19,117 @@
1919
#include <app-common/zap-generated/ids/Clusters.h>
2020
#include <app/clusters/resource-monitoring-server/resource-monitoring-cluster-objects.h>
2121
#include <app/clusters/resource-monitoring-server/resource-monitoring-server.h>
22-
#include <resource-monitoring-instances.h>
22+
#include <resource-monitoring-delegates.h>
2323

2424
using namespace chip;
2525
using namespace chip::app;
2626
using namespace chip::app::Clusters;
2727
using namespace chip::app::Clusters::ResourceMonitoring;
28+
using namespace chip::app::Clusters::ActivatedCarbonFilterMonitoring;
29+
using namespace chip::app::Clusters::HepaFilterMonitoring;
2830
using chip::Protocols::InteractionModel::Status;
2931

30-
constexpr std::bitset<4> gHepaFilterFeatureMap{ static_cast<uint32_t>(Feature::kCondition) |
31-
static_cast<uint32_t>(Feature::kWarning) |
32-
static_cast<uint32_t>(Feature::kReplacementProductList) };
33-
constexpr std::bitset<4> gActivatedCarbonFeatureMap{ static_cast<uint32_t>(Feature::kCondition) |
34-
static_cast<uint32_t>(Feature::kWarning) |
35-
static_cast<uint32_t>(Feature::kReplacementProductList) };
32+
constexpr std::bitset<4> gHepaFilterFeatureMap{ static_cast<uint32_t>(ResourceMonitoring::Feature::kCondition) |
33+
static_cast<uint32_t>(ResourceMonitoring::Feature::kWarning) |
34+
static_cast<uint32_t>(ResourceMonitoring::Feature::kReplacementProductList) };
35+
constexpr std::bitset<4> gActivatedCarbonFeatureMap{ static_cast<uint32_t>(ResourceMonitoring::Feature::kCondition) |
36+
static_cast<uint32_t>(ResourceMonitoring::Feature::kWarning) |
37+
static_cast<uint32_t>(ResourceMonitoring::Feature::kReplacementProductList) };
38+
39+
static ActivatedCarbonFilterMonitoringDelegate * gActivatedCarbonFilterDelegate = nullptr;
40+
static ResourceMonitoring::Instance * gActivatedCarbonFilterInstance = nullptr;
41+
42+
static HepaFilterMonitoringDelegate * gHepaFilterDelegate = nullptr;
43+
static ResourceMonitoring::Instance * gHepaFilterInstance = nullptr;
3644

37-
static HepaFilterMonitoringInstance * gHepaFilterInstance = nullptr;
38-
static ActivatedCarbonFilterMonitoringInstance * gActivatedCarbonFilterInstance = nullptr;
3945
static ImmutableReplacementProductListManager sReplacementProductListManager;
4046

41-
//-- Activated Carbon Filter Monitoring Instance methods
42-
CHIP_ERROR ActivatedCarbonFilterMonitoringInstance::AppInit()
47+
//-- Activated Carbon Filter Monitoring delegate methods
48+
CHIP_ERROR ActivatedCarbonFilterMonitoringDelegate::Init()
4349
{
4450
ChipLogDetail(Zcl, "ActivatedCarbonFilterMonitoringDelegate::Init()");
45-
SetReplacementProductListManagerInstance(&sReplacementProductListManager);
51+
GetInstance()->SetReplacementProductListManagerInstance(&sReplacementProductListManager);
4652
return CHIP_NO_ERROR;
4753
}
4854

49-
Status ActivatedCarbonFilterMonitoringInstance::PreResetCondition()
55+
Status ActivatedCarbonFilterMonitoringDelegate::PreResetCondition()
5056
{
51-
ChipLogDetail(Zcl, "ActivatedCarbonFilterMonitoringInstance::PreResetCondition()");
57+
ChipLogDetail(Zcl, "ActivatedCarbonFilterMonitoringDelegate::PreResetCondition()");
5258
return Status::Success;
5359
}
5460

55-
Status ActivatedCarbonFilterMonitoringInstance::PostResetCondition()
61+
Status ActivatedCarbonFilterMonitoringDelegate::PostResetCondition()
5662
{
57-
ChipLogDetail(Zcl, "ActivatedCarbonFilterMonitoringInstance::PostResetCondition()");
63+
ChipLogDetail(Zcl, "ActivatedCarbonFilterMonitoringDelegate::PostResetCondition()");
5864
return Status::Success;
5965
}
6066

61-
//-- Hepa Filter Monitoring instance methods
62-
CHIP_ERROR HepaFilterMonitoringInstance::AppInit()
67+
void ActivatedCarbonFilterMonitoring::Shutdown()
68+
{
69+
if (gActivatedCarbonFilterInstance != nullptr)
70+
{
71+
delete gActivatedCarbonFilterInstance;
72+
gActivatedCarbonFilterInstance = nullptr;
73+
}
74+
if (gActivatedCarbonFilterDelegate != nullptr)
75+
{
76+
delete gActivatedCarbonFilterDelegate;
77+
gActivatedCarbonFilterDelegate = nullptr;
78+
}
79+
}
80+
81+
//-- Hepa Filter Monitoring delegate methods
82+
CHIP_ERROR HepaFilterMonitoringDelegate::Init()
6383
{
64-
ChipLogDetail(Zcl, "HepaFilterMonitoringInstance::Init()");
65-
SetReplacementProductListManagerInstance(&sReplacementProductListManager);
84+
ChipLogDetail(Zcl, "HepaFilterMonitoringDelegate::Init()");
85+
GetInstance()->SetReplacementProductListManagerInstance(&sReplacementProductListManager);
6686
return CHIP_NO_ERROR;
6787
}
6888

69-
Status HepaFilterMonitoringInstance::PreResetCondition()
89+
Status HepaFilterMonitoringDelegate::PreResetCondition()
7090
{
71-
ChipLogDetail(Zcl, "HepaFilterMonitoringInstance::PreResetCondition()");
91+
ChipLogDetail(Zcl, "HepaFilterMonitoringDelegate::PreResetCondition()");
7292
return Status::Success;
7393
}
7494

75-
Status HepaFilterMonitoringInstance::PostResetCondition()
95+
Status HepaFilterMonitoringDelegate::PostResetCondition()
7696
{
77-
ChipLogDetail(Zcl, "HepaFilterMonitoringInstance::PostResetCondition()");
97+
ChipLogDetail(Zcl, "HepaFilterMonitoringDelegate::PostResetCondition()");
7898
return Status::Success;
7999
}
80100

101+
void HepaFilterMonitoring::Shutdown()
102+
{
103+
if (gHepaFilterInstance != nullptr)
104+
{
105+
delete gHepaFilterInstance;
106+
gHepaFilterInstance = nullptr;
107+
}
108+
if (gHepaFilterDelegate != nullptr)
109+
{
110+
delete gHepaFilterDelegate;
111+
gHepaFilterDelegate = nullptr;
112+
}
113+
}
114+
81115
void emberAfActivatedCarbonFilterMonitoringClusterInitCallback(chip::EndpointId endpoint)
82116
{
83-
VerifyOrDie(gActivatedCarbonFilterInstance == nullptr);
84-
gActivatedCarbonFilterInstance = new ActivatedCarbonFilterMonitoringInstance(
85-
endpoint, static_cast<uint32_t>(gActivatedCarbonFeatureMap.to_ulong()), DegradationDirectionEnum::kDown, true);
117+
VerifyOrDie(gActivatedCarbonFilterInstance == nullptr && gActivatedCarbonFilterDelegate == nullptr);
118+
gActivatedCarbonFilterDelegate = new ActivatedCarbonFilterMonitoringDelegate;
119+
gActivatedCarbonFilterInstance = new ResourceMonitoring::Instance(
120+
gActivatedCarbonFilterDelegate, endpoint, ActivatedCarbonFilterMonitoring::Id,
121+
static_cast<uint32_t>(gActivatedCarbonFeatureMap.to_ulong()), ResourceMonitoring::DegradationDirectionEnum::kDown, true);
86122
gActivatedCarbonFilterInstance->Init();
87123
}
124+
88125
void emberAfHepaFilterMonitoringClusterInitCallback(chip::EndpointId endpoint)
89126
{
90-
VerifyOrDie(gHepaFilterInstance == nullptr);
91-
gHepaFilterInstance = new HepaFilterMonitoringInstance(endpoint, static_cast<uint32_t>(gHepaFilterFeatureMap.to_ulong()),
92-
DegradationDirectionEnum::kDown, true);
127+
VerifyOrDie(gHepaFilterInstance == nullptr && gHepaFilterDelegate == nullptr);
128+
129+
gHepaFilterDelegate = new HepaFilterMonitoringDelegate;
130+
gHepaFilterInstance = new ResourceMonitoring::Instance(gHepaFilterDelegate, endpoint, HepaFilterMonitoring::Id,
131+
static_cast<uint32_t>(gHepaFilterFeatureMap.to_ulong()),
132+
ResourceMonitoring::DegradationDirectionEnum::kDown, true);
93133
gHepaFilterInstance->Init();
94134
}
95135

examples/all-clusters-app/ameba/chip_main.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ list(
156156
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp
157157
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp
158158
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp
159-
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-instances.cpp
159+
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-delegates.cpp
160160
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp
161161
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp
162162
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp

examples/all-clusters-app/asr/BUILD.gn

+1-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ asr_executable("clusters_app") {
7474
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
7575
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
7676
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
77-
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-instances.cpp",
77+
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-delegates.cpp",
7878
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
7979
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",
8080
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp",

examples/all-clusters-app/cc13x2x7_26x2x7/BUILD.gn

+1-1
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ ti_simplelink_executable("all-clusters-app") {
7979
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
8080
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
8181
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
82-
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-instances.cpp",
82+
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-delegates.cpp",
8383
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
8484
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",
8585
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp",

examples/all-clusters-app/cc13x4_26x4/BUILD.gn

+1-1
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ ti_simplelink_executable("all-clusters-app") {
7979
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
8080
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
8181
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
82-
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-instances.cpp",
82+
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-delegates.cpp",
8383
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
8484
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",
8585
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp",

examples/all-clusters-app/infineon/psoc6/BUILD.gn

+1-1
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ psoc6_executable("clusters_app") {
110110
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
111111
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
112112
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
113-
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-instances.cpp",
113+
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-delegates.cpp",
114114
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
115115
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",
116116
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp",

examples/all-clusters-app/linux/BUILD.gn

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ source_set("chip-all-clusters-common") {
3131
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/laundry-washer-controls-delegate-impl.cpp",
3232
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/laundry-washer-mode.cpp",
3333
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/operational-state-delegate-impl.cpp",
34-
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-instances.cpp",
34+
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-delegates.cpp",
3535
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/rvc-modes.cpp",
3636
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
3737
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",

examples/all-clusters-app/linux/main-common.cpp

+3
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
#include "laundry-washer-controls-delegate-impl.h"
2525
#include "laundry-washer-mode.h"
2626
#include "operational-state-delegate-impl.h"
27+
#include "resource-monitoring-delegates.h"
2728
#include "rvc-modes.h"
2829
#include "tcc-mode.h"
2930
#include <app-common/zap-generated/attributes/Accessors.h>
@@ -227,6 +228,8 @@ void ApplicationShutdown()
227228
Clusters::RvcCleanMode::Shutdown();
228229
Clusters::RvcRunMode::Shutdown();
229230
Clusters::RefrigeratorAndTemperatureControlledCabinetMode::Shutdown();
231+
Clusters::HepaFilterMonitoring::Shutdown();
232+
Clusters::ActivatedCarbonFilterMonitoring::Shutdown();
230233

231234
Clusters::AirQuality::Shutdown();
232235
Clusters::OperationalState::Shutdown();

examples/all-clusters-app/mbed/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ target_sources(${APP_TARGET} PRIVATE
6262
${ALL_CLUSTERS_COMMON}/src/bridged-actions-stub.cpp
6363
${ALL_CLUSTERS_COMMON}/src/concentration-measurement-instances.cpp
6464
${ALL_CLUSTERS_COMMON}/src/fan-stub.cpp
65-
${ALL_CLUSTERS_COMMON}/src/resource-monitoring-instances.cpp
65+
${ALL_CLUSTERS_COMMON}/src/resource-monitoring-delegates.cpp
6666
${ALL_CLUSTERS_COMMON}/src/smco-stub.cpp
6767
${ALL_CLUSTERS_COMMON}/src/static-supported-modes-manager.cpp
6868
${ALL_CLUSTERS_COMMON}/src/static-supported-temperature-levels.cpp

examples/all-clusters-app/nrfconnect/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ target_sources(app PRIVATE
6464
${ALL_CLUSTERS_COMMON_DIR}/src/fan-stub.cpp
6565
${ALL_CLUSTERS_COMMON_DIR}/src/binding-handler.cpp
6666
${ALL_CLUSTERS_COMMON_DIR}/src/concentration-measurement-instances.cpp
67-
${ALL_CLUSTERS_COMMON_DIR}/src/resource-monitoring-instances.cpp
67+
${ALL_CLUSTERS_COMMON_DIR}/src/resource-monitoring-delegates.cpp
6868
${NRFCONNECT_COMMON}/util/LEDWidget.cpp)
6969

7070
chip_configure_data_model(app

examples/all-clusters-app/nxp/mw320/BUILD.gn

+1-1
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ mw320_executable("shell_mw320") {
7777
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
7878
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
7979
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
80-
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-instances.cpp",
80+
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-delegates.cpp",
8181
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
8282
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",
8383
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp",

examples/all-clusters-app/openiotsdk/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ target_sources(${APP_TARGET}
5656
${ALL_CLUSTERS_COMMON}/src/bridged-actions-stub.cpp
5757
${ALL_CLUSTERS_COMMON}/src/concentration-measurement-instances.cpp
5858
${ALL_CLUSTERS_COMMON}/src/fan-stub.cpp
59-
${ALL_CLUSTERS_COMMON}/src/resource-monitoring-instances.cpp
59+
${ALL_CLUSTERS_COMMON}/src/resource-monitoring-delegates.cpp
6060
${ALL_CLUSTERS_COMMON}/src/static-supported-modes-manager.cpp
6161
${ALL_CLUSTERS_COMMON}/src/binding-handler.cpp
6262
)

examples/all-clusters-app/telink/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ target_sources(app PRIVATE
7878
${ALL_CLUSTERS_COMMON_DIR}/src/binding-handler.cpp
7979
${ALL_CLUSTERS_COMMON_DIR}/src/concentration-measurement-instances.cpp
8080
${ALL_CLUSTERS_COMMON_DIR}/src/fan-stub.cpp
81-
${ALL_CLUSTERS_COMMON_DIR}/src/resource-monitoring-instances.cpp
81+
${ALL_CLUSTERS_COMMON_DIR}/src/resource-monitoring-delegates.cpp
8282
${TELINK_COMMON}/common/src/mainCommon.cpp
8383
${TELINK_COMMON}/common/src/AppTaskCommon.cpp
8484
${TELINK_COMMON}/util/src/LEDWidget.cpp

examples/all-clusters-app/tizen/BUILD.gn

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ source_set("chip-all-clusters-common") {
2727
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
2828
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
2929
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
30-
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-instances.cpp",
30+
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-delegates.cpp",
3131
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
3232
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",
3333
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp",

examples/placeholder/linux/apps/app1/BUILD.gn

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ source_set("app1") {
3030
]
3131

3232
sources = [
33-
"../../resource-monitoring-instances.cpp",
33+
"../../resource-monitoring-delegates.cpp",
3434
"../../src/bridged-actions-stub.cpp",
3535
"../../static-supported-modes-manager.cpp",
3636
]

examples/placeholder/linux/apps/app2/BUILD.gn

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ source_set("app2") {
3030
]
3131

3232
sources = [
33-
"../../resource-monitoring-instances.cpp",
33+
"../../resource-monitoring-delegates.cpp",
3434
"../../src/bridged-actions-stub.cpp",
3535
"../../static-supported-modes-manager.cpp",
3636
]

0 commit comments

Comments
 (0)