diff --git a/examples/all-clusters-app/all-clusters-common/all-clusters-app.matter b/examples/all-clusters-app/all-clusters-common/all-clusters-app.matter index ea90c395ed6bc5..3bde7431a262ad 100644 --- a/examples/all-clusters-app/all-clusters-common/all-clusters-app.matter +++ b/examples/all-clusters-app/all-clusters-common/all-clusters-app.matter @@ -2686,29 +2686,29 @@ server cluster PumpConfigurationAndControl = 512 { info event TurbineOperation = 16 { } - readonly attribute int16s maxPressure = 0; - readonly attribute int16u maxSpeed = 1; - readonly attribute int16u maxFlow = 2; - readonly attribute int16s minConstPressure = 3; - readonly attribute int16s maxConstPressure = 4; - readonly attribute int16s minCompPressure = 5; - readonly attribute int16s maxCompPressure = 6; - readonly attribute int16u minConstSpeed = 7; - readonly attribute int16u maxConstSpeed = 8; - readonly attribute int16u minConstFlow = 9; - readonly attribute int16u maxConstFlow = 10; - readonly attribute int16s minConstTemp = 11; - readonly attribute int16s maxConstTemp = 12; + readonly attribute nullable int16s maxPressure = 0; + readonly attribute nullable int16u maxSpeed = 1; + readonly attribute nullable int16u maxFlow = 2; + readonly attribute nullable int16s minConstPressure = 3; + readonly attribute nullable int16s maxConstPressure = 4; + readonly attribute nullable int16s minCompPressure = 5; + readonly attribute nullable int16s maxCompPressure = 6; + readonly attribute nullable int16u minConstSpeed = 7; + readonly attribute nullable int16u maxConstSpeed = 8; + readonly attribute nullable int16u minConstFlow = 9; + readonly attribute nullable int16u maxConstFlow = 10; + readonly attribute nullable int16s minConstTemp = 11; + readonly attribute nullable int16s maxConstTemp = 12; readonly attribute bitmap16 pumpStatus = 16; - readonly attribute enum8 effectiveOperationMode = 17; - readonly attribute enum8 effectiveControlMode = 18; - readonly attribute int16s capacity = 19; - readonly attribute int16u speed = 20; - attribute nullable int24u lifetimeRunningHours = 21; - readonly attribute int24u power = 22; - attribute nullable int32u lifetimeEnergyConsumed = 23; - attribute enum8 operationMode = 32; - attribute enum8 controlMode = 33; + readonly attribute PumpOperationMode effectiveOperationMode = 17; + readonly attribute PumpControlMode effectiveControlMode = 18; + readonly attribute nullable int16s capacity = 19; + readonly attribute nullable int16u speed = 20; + attribute access(write: manage) nullable int24u lifetimeRunningHours = 21; + readonly attribute nullable int24u power = 22; + attribute access(write: manage) nullable int32u lifetimeEnergyConsumed = 23; + attribute access(write: manage) PumpOperationMode operationMode = 32; + attribute access(write: manage) PumpControlMode controlMode = 33; readonly attribute bitmap16 alarmMask = 34; readonly attribute bitmap32 featureMap = 65532; readonly attribute int16u clusterRevision = 65533; diff --git a/examples/placeholder/linux/apps/app1/config.matter b/examples/placeholder/linux/apps/app1/config.matter index 39da75e07e4fa2..4cf6ec23132d6a 100644 --- a/examples/placeholder/linux/apps/app1/config.matter +++ b/examples/placeholder/linux/apps/app1/config.matter @@ -1888,29 +1888,29 @@ server cluster PumpConfigurationAndControl = 512 { info event TurbineOperation = 16 { } - readonly attribute int16s maxPressure = 0; - readonly attribute int16u maxSpeed = 1; - readonly attribute int16u maxFlow = 2; - readonly attribute int16s minConstPressure = 3; - readonly attribute int16s maxConstPressure = 4; - readonly attribute int16s minCompPressure = 5; - readonly attribute int16s maxCompPressure = 6; - readonly attribute int16u minConstSpeed = 7; - readonly attribute int16u maxConstSpeed = 8; - readonly attribute int16u minConstFlow = 9; - readonly attribute int16u maxConstFlow = 10; - readonly attribute int16s minConstTemp = 11; - readonly attribute int16s maxConstTemp = 12; + readonly attribute nullable int16s maxPressure = 0; + readonly attribute nullable int16u maxSpeed = 1; + readonly attribute nullable int16u maxFlow = 2; + readonly attribute nullable int16s minConstPressure = 3; + readonly attribute nullable int16s maxConstPressure = 4; + readonly attribute nullable int16s minCompPressure = 5; + readonly attribute nullable int16s maxCompPressure = 6; + readonly attribute nullable int16u minConstSpeed = 7; + readonly attribute nullable int16u maxConstSpeed = 8; + readonly attribute nullable int16u minConstFlow = 9; + readonly attribute nullable int16u maxConstFlow = 10; + readonly attribute nullable int16s minConstTemp = 11; + readonly attribute nullable int16s maxConstTemp = 12; readonly attribute bitmap16 pumpStatus = 16; - readonly attribute enum8 effectiveOperationMode = 17; - readonly attribute enum8 effectiveControlMode = 18; - readonly attribute int16s capacity = 19; - readonly attribute int16u speed = 20; - attribute nullable int24u lifetimeRunningHours = 21; - readonly attribute int24u power = 22; - attribute nullable int32u lifetimeEnergyConsumed = 23; - attribute enum8 operationMode = 32; - attribute enum8 controlMode = 33; + readonly attribute PumpOperationMode effectiveOperationMode = 17; + readonly attribute PumpControlMode effectiveControlMode = 18; + readonly attribute nullable int16s capacity = 19; + readonly attribute nullable int16u speed = 20; + attribute access(write: manage) nullable int24u lifetimeRunningHours = 21; + readonly attribute nullable int24u power = 22; + attribute access(write: manage) nullable int32u lifetimeEnergyConsumed = 23; + attribute access(write: manage) PumpOperationMode operationMode = 32; + attribute access(write: manage) PumpControlMode controlMode = 33; readonly attribute bitmap16 alarmMask = 34; readonly attribute bitmap32 featureMap = 65532; readonly attribute int16u clusterRevision = 65533; diff --git a/examples/placeholder/linux/apps/app2/config.matter b/examples/placeholder/linux/apps/app2/config.matter index 39da75e07e4fa2..4cf6ec23132d6a 100644 --- a/examples/placeholder/linux/apps/app2/config.matter +++ b/examples/placeholder/linux/apps/app2/config.matter @@ -1888,29 +1888,29 @@ server cluster PumpConfigurationAndControl = 512 { info event TurbineOperation = 16 { } - readonly attribute int16s maxPressure = 0; - readonly attribute int16u maxSpeed = 1; - readonly attribute int16u maxFlow = 2; - readonly attribute int16s minConstPressure = 3; - readonly attribute int16s maxConstPressure = 4; - readonly attribute int16s minCompPressure = 5; - readonly attribute int16s maxCompPressure = 6; - readonly attribute int16u minConstSpeed = 7; - readonly attribute int16u maxConstSpeed = 8; - readonly attribute int16u minConstFlow = 9; - readonly attribute int16u maxConstFlow = 10; - readonly attribute int16s minConstTemp = 11; - readonly attribute int16s maxConstTemp = 12; + readonly attribute nullable int16s maxPressure = 0; + readonly attribute nullable int16u maxSpeed = 1; + readonly attribute nullable int16u maxFlow = 2; + readonly attribute nullable int16s minConstPressure = 3; + readonly attribute nullable int16s maxConstPressure = 4; + readonly attribute nullable int16s minCompPressure = 5; + readonly attribute nullable int16s maxCompPressure = 6; + readonly attribute nullable int16u minConstSpeed = 7; + readonly attribute nullable int16u maxConstSpeed = 8; + readonly attribute nullable int16u minConstFlow = 9; + readonly attribute nullable int16u maxConstFlow = 10; + readonly attribute nullable int16s minConstTemp = 11; + readonly attribute nullable int16s maxConstTemp = 12; readonly attribute bitmap16 pumpStatus = 16; - readonly attribute enum8 effectiveOperationMode = 17; - readonly attribute enum8 effectiveControlMode = 18; - readonly attribute int16s capacity = 19; - readonly attribute int16u speed = 20; - attribute nullable int24u lifetimeRunningHours = 21; - readonly attribute int24u power = 22; - attribute nullable int32u lifetimeEnergyConsumed = 23; - attribute enum8 operationMode = 32; - attribute enum8 controlMode = 33; + readonly attribute PumpOperationMode effectiveOperationMode = 17; + readonly attribute PumpControlMode effectiveControlMode = 18; + readonly attribute nullable int16s capacity = 19; + readonly attribute nullable int16u speed = 20; + attribute access(write: manage) nullable int24u lifetimeRunningHours = 21; + readonly attribute nullable int24u power = 22; + attribute access(write: manage) nullable int32u lifetimeEnergyConsumed = 23; + attribute access(write: manage) PumpOperationMode operationMode = 32; + attribute access(write: manage) PumpControlMode controlMode = 33; readonly attribute bitmap16 alarmMask = 34; readonly attribute bitmap32 featureMap = 65532; readonly attribute int16u clusterRevision = 65533; diff --git a/examples/pump-app/pump-common/pump-app.matter b/examples/pump-app/pump-common/pump-app.matter index 2303484b2d9c74..914510c6fd4973 100644 --- a/examples/pump-app/pump-common/pump-app.matter +++ b/examples/pump-app/pump-common/pump-app.matter @@ -1189,29 +1189,29 @@ server cluster PumpConfigurationAndControl = 512 { info event TurbineOperation = 16 { } - readonly attribute int16s maxPressure = 0; - readonly attribute int16u maxSpeed = 1; - readonly attribute int16u maxFlow = 2; - readonly attribute int16s minConstPressure = 3; - readonly attribute int16s maxConstPressure = 4; - readonly attribute int16s minCompPressure = 5; - readonly attribute int16s maxCompPressure = 6; - readonly attribute int16u minConstSpeed = 7; - readonly attribute int16u maxConstSpeed = 8; - readonly attribute int16u minConstFlow = 9; - readonly attribute int16u maxConstFlow = 10; - readonly attribute int16s minConstTemp = 11; - readonly attribute int16s maxConstTemp = 12; + readonly attribute nullable int16s maxPressure = 0; + readonly attribute nullable int16u maxSpeed = 1; + readonly attribute nullable int16u maxFlow = 2; + readonly attribute nullable int16s minConstPressure = 3; + readonly attribute nullable int16s maxConstPressure = 4; + readonly attribute nullable int16s minCompPressure = 5; + readonly attribute nullable int16s maxCompPressure = 6; + readonly attribute nullable int16u minConstSpeed = 7; + readonly attribute nullable int16u maxConstSpeed = 8; + readonly attribute nullable int16u minConstFlow = 9; + readonly attribute nullable int16u maxConstFlow = 10; + readonly attribute nullable int16s minConstTemp = 11; + readonly attribute nullable int16s maxConstTemp = 12; readonly attribute bitmap16 pumpStatus = 16; - readonly attribute enum8 effectiveOperationMode = 17; - readonly attribute enum8 effectiveControlMode = 18; - readonly attribute int16s capacity = 19; - readonly attribute int16u speed = 20; - attribute nullable int24u lifetimeRunningHours = 21; - readonly attribute int24u power = 22; - attribute nullable int32u lifetimeEnergyConsumed = 23; - attribute enum8 operationMode = 32; - attribute enum8 controlMode = 33; + readonly attribute PumpOperationMode effectiveOperationMode = 17; + readonly attribute PumpControlMode effectiveControlMode = 18; + readonly attribute nullable int16s capacity = 19; + readonly attribute nullable int16u speed = 20; + attribute access(write: manage) nullable int24u lifetimeRunningHours = 21; + readonly attribute nullable int24u power = 22; + attribute access(write: manage) nullable int32u lifetimeEnergyConsumed = 23; + attribute access(write: manage) PumpOperationMode operationMode = 32; + attribute access(write: manage) PumpControlMode controlMode = 33; readonly attribute bitmap16 alarmMask = 34; readonly attribute bitmap32 featureMap = 65532; readonly attribute int16u clusterRevision = 65533; diff --git a/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter b/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter index 7ad2695c4680b9..35d673a6f45a97 100644 --- a/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter +++ b/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter @@ -1050,13 +1050,13 @@ client cluster PumpConfigurationAndControl = 512 { info event TurbineOperation = 16 { } - readonly attribute int16s maxPressure = 0; - readonly attribute int16u maxSpeed = 1; - readonly attribute int16u maxFlow = 2; - readonly attribute enum8 effectiveOperationMode = 17; - readonly attribute enum8 effectiveControlMode = 18; - readonly attribute int16s capacity = 19; - attribute enum8 operationMode = 32; + readonly attribute nullable int16s maxPressure = 0; + readonly attribute nullable int16u maxSpeed = 1; + readonly attribute nullable int16u maxFlow = 2; + readonly attribute PumpOperationMode effectiveOperationMode = 17; + readonly attribute PumpControlMode effectiveControlMode = 18; + readonly attribute nullable int16s capacity = 19; + attribute access(write: manage) PumpOperationMode operationMode = 32; readonly attribute int16u clusterRevision = 65533; } diff --git a/src/app/clusters/pump-configuration-and-control-server/pump-configuration-and-control-server.cpp b/src/app/clusters/pump-configuration-and-control-server/pump-configuration-and-control-server.cpp index c830a543f24583..3108f1fc2259a8 100644 --- a/src/app/clusters/pump-configuration-and-control-server/pump-configuration-and-control-server.cpp +++ b/src/app/clusters/pump-configuration-and-control-server/pump-configuration-and-control-server.cpp @@ -24,6 +24,7 @@ #include using namespace chip; +using namespace chip::app::Clusters::PumpConfigurationAndControl; using namespace chip::app::Clusters::PumpConfigurationAndControl::Attributes; void emberAfPumpConfigurationAndControlClusterServerInitCallback(EndpointId endpoint) @@ -40,15 +41,15 @@ void MatterPumpConfigurationAndControlClusterServerAttributeChangedCallback(cons switch (attributePath.mAttributeId) { case ControlMode::Id: { - uint8_t value; - ControlMode::Get(attributePath.mEndpointId, &value); - EffectiveControlMode::Set(attributePath.mEndpointId, value); + PumpControlMode controlMode; + ControlMode::Get(attributePath.mEndpointId, &controlMode); + EffectiveControlMode::Set(attributePath.mEndpointId, controlMode); } break; case OperationMode::Id: { - uint8_t value; - OperationMode::Get(attributePath.mEndpointId, &value); - EffectiveOperationMode::Set(attributePath.mEndpointId, value); + PumpOperationMode operationMode; + OperationMode::Get(attributePath.mEndpointId, &operationMode); + EffectiveOperationMode::Set(attributePath.mEndpointId, operationMode); } break; default: diff --git a/src/app/zap-templates/zcl/data-model/chip/pump-configuration-and-control-cluster.xml b/src/app/zap-templates/zcl/data-model/chip/pump-configuration-and-control-cluster.xml index 7adb0526d4da62..7074810fc6f00a 100644 --- a/src/app/zap-templates/zcl/data-model/chip/pump-configuration-and-control-cluster.xml +++ b/src/app/zap-templates/zcl/data-model/chip/pump-configuration-and-control-cluster.xml @@ -24,30 +24,47 @@ limitations under the License. PUMP_CONFIG_CONTROL_CLUSTER true true - MaxPressure - MaxSpeed - MaxFlow - MinConstPressure - MaxConstPressure - MinCompPressure - MaxCompPressure - MinConstSpeed - MaxConstSpeed - MinConstFlow - MaxConstFlow - MinConstTemp - MaxConstTemp + + MaxPressure + MaxSpeed + MaxFlow + MinConstPressure + MaxConstPressure + MinCompPressure + MaxCompPressure + MinConstSpeed + MaxConstSpeed + MinConstFlow + MaxConstFlow + MinConstTemp + MaxConstTemp PumpStatus - EffectiveOperationMode - EffectiveControlMode - Capacity - Speed - LifetimeRunningHours - Power - LifetimeEnergyConsumed - OperationMode - ControlMode - AlarmMask + EffectiveOperationMode + EffectiveControlMode + Capacity + Speed + + LifetimeRunningHours + + + + Power + + LifetimeEnergyConsumed + + + + + OperationMode + + + + + ControlMode + + + + AlarmMask SupplyVoltageLow diff --git a/src/controller/data_model/controller-clusters.matter b/src/controller/data_model/controller-clusters.matter index cb8a42792c0d56..f7ce3c6c6fdd1b 100644 --- a/src/controller/data_model/controller-clusters.matter +++ b/src/controller/data_model/controller-clusters.matter @@ -3138,29 +3138,29 @@ client cluster PumpConfigurationAndControl = 512 { info event TurbineOperation = 16 { } - readonly attribute int16s maxPressure = 0; - readonly attribute int16u maxSpeed = 1; - readonly attribute int16u maxFlow = 2; - readonly attribute int16s minConstPressure = 3; - readonly attribute int16s maxConstPressure = 4; - readonly attribute int16s minCompPressure = 5; - readonly attribute int16s maxCompPressure = 6; - readonly attribute int16u minConstSpeed = 7; - readonly attribute int16u maxConstSpeed = 8; - readonly attribute int16u minConstFlow = 9; - readonly attribute int16u maxConstFlow = 10; - readonly attribute int16s minConstTemp = 11; - readonly attribute int16s maxConstTemp = 12; + readonly attribute nullable int16s maxPressure = 0; + readonly attribute nullable int16u maxSpeed = 1; + readonly attribute nullable int16u maxFlow = 2; + readonly attribute nullable int16s minConstPressure = 3; + readonly attribute nullable int16s maxConstPressure = 4; + readonly attribute nullable int16s minCompPressure = 5; + readonly attribute nullable int16s maxCompPressure = 6; + readonly attribute nullable int16u minConstSpeed = 7; + readonly attribute nullable int16u maxConstSpeed = 8; + readonly attribute nullable int16u minConstFlow = 9; + readonly attribute nullable int16u maxConstFlow = 10; + readonly attribute nullable int16s minConstTemp = 11; + readonly attribute nullable int16s maxConstTemp = 12; readonly attribute bitmap16 pumpStatus = 16; - readonly attribute enum8 effectiveOperationMode = 17; - readonly attribute enum8 effectiveControlMode = 18; - readonly attribute int16s capacity = 19; - readonly attribute int16u speed = 20; - attribute nullable int24u lifetimeRunningHours = 21; - readonly attribute int24u power = 22; - attribute nullable int32u lifetimeEnergyConsumed = 23; - attribute enum8 operationMode = 32; - attribute enum8 controlMode = 33; + readonly attribute PumpOperationMode effectiveOperationMode = 17; + readonly attribute PumpControlMode effectiveControlMode = 18; + readonly attribute nullable int16s capacity = 19; + readonly attribute nullable int16u speed = 20; + attribute access(write: manage) nullable int24u lifetimeRunningHours = 21; + readonly attribute nullable int24u power = 22; + attribute access(write: manage) nullable int32u lifetimeEnergyConsumed = 23; + attribute access(write: manage) PumpOperationMode operationMode = 32; + attribute access(write: manage) PumpControlMode controlMode = 33; readonly attribute bitmap16 alarmMask = 34; readonly attribute command_id generatedCommandList[] = 65528; readonly attribute command_id acceptedCommandList[] = 65529; diff --git a/src/controller/java/zap-generated/CHIPAttributeTLVValueDecoder.cpp b/src/controller/java/zap-generated/CHIPAttributeTLVValueDecoder.cpp index b1627ce95c6069..ace18bd982ad11 100644 --- a/src/controller/java/zap-generated/CHIPAttributeTLVValueDecoder.cpp +++ b/src/controller/java/zap-generated/CHIPAttributeTLVValueDecoder.cpp @@ -10322,10 +10322,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::MaxSpeed::Id: { @@ -10337,10 +10344,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::MaxFlow::Id: { @@ -10352,10 +10366,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::MinConstPressure::Id: { @@ -10367,10 +10388,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::MaxConstPressure::Id: { @@ -10382,10 +10410,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::MinCompPressure::Id: { @@ -10397,10 +10432,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::MaxCompPressure::Id: { @@ -10412,10 +10454,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::MinConstSpeed::Id: { @@ -10427,10 +10476,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::MaxConstSpeed::Id: { @@ -10442,10 +10498,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::MinConstFlow::Id: { @@ -10457,10 +10520,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::MaxConstFlow::Id: { @@ -10472,10 +10542,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::MinConstTemp::Id: { @@ -10487,10 +10564,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::MaxConstTemp::Id: { @@ -10502,10 +10586,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::PumpStatus::Id: { @@ -10535,7 +10626,7 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR std::string valueClassName = "java/lang/Integer"; std::string valueCtorSignature = "(I)V"; chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + static_cast(cppValue), value); return value; } case Attributes::EffectiveControlMode::Id: { @@ -10550,7 +10641,7 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR std::string valueClassName = "java/lang/Integer"; std::string valueCtorSignature = "(I)V"; chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + static_cast(cppValue), value); return value; } case Attributes::Capacity::Id: { @@ -10562,10 +10653,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::Speed::Id: { @@ -10577,10 +10675,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Integer"; - std::string valueCtorSignature = "(I)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Integer"; + std::string valueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::LifetimeRunningHours::Id: { @@ -10614,10 +10719,17 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR return nullptr; } jobject value; - std::string valueClassName = "java/lang/Long"; - std::string valueCtorSignature = "(J)V"; - chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + if (cppValue.IsNull()) + { + value = nullptr; + } + else + { + std::string valueClassName = "java/lang/Long"; + std::string valueCtorSignature = "(J)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), + cppValue.Value(), value); + } return value; } case Attributes::LifetimeEnergyConsumed::Id: { @@ -10654,7 +10766,7 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR std::string valueClassName = "java/lang/Integer"; std::string valueCtorSignature = "(I)V"; chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + static_cast(cppValue), value); return value; } case Attributes::ControlMode::Id: { @@ -10669,7 +10781,7 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR std::string valueClassName = "java/lang/Integer"; std::string valueCtorSignature = "(I)V"; chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + static_cast(cppValue), value); return value; } case Attributes::AlarmMask::Id: { diff --git a/src/controller/java/zap-generated/CHIPReadCallbacks.cpp b/src/controller/java/zap-generated/CHIPReadCallbacks.cpp index 92d765301a9dcf..444a10867939e0 100644 --- a/src/controller/java/zap-generated/CHIPReadCallbacks.cpp +++ b/src/controller/java/zap-generated/CHIPReadCallbacks.cpp @@ -15496,6 +15496,1013 @@ void CHIPPressureMeasurementAttributeListAttributeCallback::CallbackFn( env->CallVoidMethod(javaCallbackRef, javaMethod, arrayListObj); } +CHIPPumpConfigurationAndControlMaxPressureAttributeCallback::CHIPPumpConfigurationAndControlMaxPressureAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlMaxPressureAttributeCallback::~CHIPPumpConfigurationAndControlMaxPressureAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlMaxPressureAttributeCallback::CallbackFn(void * context, + const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlMaxSpeedAttributeCallback::CHIPPumpConfigurationAndControlMaxSpeedAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlMaxSpeedAttributeCallback::~CHIPPumpConfigurationAndControlMaxSpeedAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlMaxSpeedAttributeCallback::CallbackFn(void * context, + const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlMaxFlowAttributeCallback::CHIPPumpConfigurationAndControlMaxFlowAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlMaxFlowAttributeCallback::~CHIPPumpConfigurationAndControlMaxFlowAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlMaxFlowAttributeCallback::CallbackFn(void * context, + const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlMinConstPressureAttributeCallback::CHIPPumpConfigurationAndControlMinConstPressureAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlMinConstPressureAttributeCallback:: + ~CHIPPumpConfigurationAndControlMinConstPressureAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlMinConstPressureAttributeCallback::CallbackFn( + void * context, const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlMaxConstPressureAttributeCallback::CHIPPumpConfigurationAndControlMaxConstPressureAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlMaxConstPressureAttributeCallback:: + ~CHIPPumpConfigurationAndControlMaxConstPressureAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlMaxConstPressureAttributeCallback::CallbackFn( + void * context, const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlMinCompPressureAttributeCallback::CHIPPumpConfigurationAndControlMinCompPressureAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlMinCompPressureAttributeCallback::~CHIPPumpConfigurationAndControlMinCompPressureAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlMinCompPressureAttributeCallback::CallbackFn( + void * context, const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlMaxCompPressureAttributeCallback::CHIPPumpConfigurationAndControlMaxCompPressureAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlMaxCompPressureAttributeCallback::~CHIPPumpConfigurationAndControlMaxCompPressureAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlMaxCompPressureAttributeCallback::CallbackFn( + void * context, const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlMinConstSpeedAttributeCallback::CHIPPumpConfigurationAndControlMinConstSpeedAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlMinConstSpeedAttributeCallback::~CHIPPumpConfigurationAndControlMinConstSpeedAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlMinConstSpeedAttributeCallback::CallbackFn( + void * context, const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlMaxConstSpeedAttributeCallback::CHIPPumpConfigurationAndControlMaxConstSpeedAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlMaxConstSpeedAttributeCallback::~CHIPPumpConfigurationAndControlMaxConstSpeedAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlMaxConstSpeedAttributeCallback::CallbackFn( + void * context, const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlMinConstFlowAttributeCallback::CHIPPumpConfigurationAndControlMinConstFlowAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlMinConstFlowAttributeCallback::~CHIPPumpConfigurationAndControlMinConstFlowAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlMinConstFlowAttributeCallback::CallbackFn( + void * context, const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlMaxConstFlowAttributeCallback::CHIPPumpConfigurationAndControlMaxConstFlowAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlMaxConstFlowAttributeCallback::~CHIPPumpConfigurationAndControlMaxConstFlowAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlMaxConstFlowAttributeCallback::CallbackFn( + void * context, const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlMinConstTempAttributeCallback::CHIPPumpConfigurationAndControlMinConstTempAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlMinConstTempAttributeCallback::~CHIPPumpConfigurationAndControlMinConstTempAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlMinConstTempAttributeCallback::CallbackFn(void * context, + const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlMaxConstTempAttributeCallback::CHIPPumpConfigurationAndControlMaxConstTempAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlMaxConstTempAttributeCallback::~CHIPPumpConfigurationAndControlMaxConstTempAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlMaxConstTempAttributeCallback::CallbackFn(void * context, + const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlCapacityAttributeCallback::CHIPPumpConfigurationAndControlCapacityAttributeCallback( + jobject javaCallback, bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlCapacityAttributeCallback::~CHIPPumpConfigurationAndControlCapacityAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlCapacityAttributeCallback::CallbackFn(void * context, + const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + +CHIPPumpConfigurationAndControlSpeedAttributeCallback::CHIPPumpConfigurationAndControlSpeedAttributeCallback(jobject javaCallback, + bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlSpeedAttributeCallback::~CHIPPumpConfigurationAndControlSpeedAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlSpeedAttributeCallback::CallbackFn(void * context, + const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Integer"; + std::string javaValueCtorSignature = "(I)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + CHIPPumpConfigurationAndControlLifetimeRunningHoursAttributeCallback:: CHIPPumpConfigurationAndControlLifetimeRunningHoursAttributeCallback(jobject javaCallback, bool keepAlive) : chip::Callback::Callback(CallbackFn, this), @@ -15564,6 +16571,73 @@ void CHIPPumpConfigurationAndControlLifetimeRunningHoursAttributeCallback::Callb env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); } +CHIPPumpConfigurationAndControlPowerAttributeCallback::CHIPPumpConfigurationAndControlPowerAttributeCallback(jobject javaCallback, + bool keepAlive) : + chip::Callback::Callback(CallbackFn, this), + keepAlive(keepAlive) +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPPumpConfigurationAndControlPowerAttributeCallback::~CHIPPumpConfigurationAndControlPowerAttributeCallback() +{ + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +} + +void CHIPPumpConfigurationAndControlPowerAttributeCallback::CallbackFn(void * context, + const chip::app::DataModel::Nullable & value) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env")); + std::unique_ptr cppCallback( + reinterpret_cast(context), maybeDestroy); + + // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback. + javaCallbackRef = cppCallback.get()->javaCallbackRef; + VerifyOrReturn(javaCallbackRef != nullptr, + ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null")); + + jmethodID javaMethod; + err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Long;)V", &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method")); + + jobject javaValue; + if (value.IsNull()) + { + javaValue = nullptr; + } + else + { + std::string javaValueClassName = "java/lang/Long"; + std::string javaValueCtorSignature = "(J)V"; + chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(), + value.Value(), javaValue); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue); +} + CHIPPumpConfigurationAndControlLifetimeEnergyConsumedAttributeCallback:: CHIPPumpConfigurationAndControlLifetimeEnergyConsumedAttributeCallback(jobject javaCallback, bool keepAlive) : chip::Callback::Callback(CallbackFn, this), diff --git a/src/controller/java/zap-generated/CHIPReadCallbacks.h b/src/controller/java/zap-generated/CHIPReadCallbacks.h index 301df11bce6430..08653886c9758d 100644 --- a/src/controller/java/zap-generated/CHIPReadCallbacks.h +++ b/src/controller/java/zap-generated/CHIPReadCallbacks.h @@ -6429,6 +6429,456 @@ class CHIPPressureMeasurementAttributeListAttributeCallback bool keepAlive; }; +class CHIPPumpConfigurationAndControlMaxPressureAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlMaxPressureAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlMaxPressureAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlMaxPressureAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlMaxSpeedAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlMaxSpeedAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlMaxSpeedAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlMaxSpeedAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlMaxFlowAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlMaxFlowAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlMaxFlowAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlMaxFlowAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlMinConstPressureAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlMinConstPressureAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlMinConstPressureAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlMinConstPressureAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlMaxConstPressureAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlMaxConstPressureAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlMaxConstPressureAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlMaxConstPressureAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlMinCompPressureAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlMinCompPressureAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlMinCompPressureAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlMinCompPressureAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlMaxCompPressureAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlMaxCompPressureAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlMaxCompPressureAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlMaxCompPressureAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlMinConstSpeedAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlMinConstSpeedAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlMinConstSpeedAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlMinConstSpeedAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlMaxConstSpeedAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlMaxConstSpeedAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlMaxConstSpeedAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlMaxConstSpeedAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlMinConstFlowAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlMinConstFlowAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlMinConstFlowAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlMinConstFlowAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlMaxConstFlowAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlMaxConstFlowAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlMaxConstFlowAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlMaxConstFlowAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlMinConstTempAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlMinConstTempAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlMinConstTempAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlMinConstTempAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlMaxConstTempAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlMaxConstTempAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlMaxConstTempAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlMaxConstTempAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlCapacityAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlCapacityAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlCapacityAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlCapacityAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + +class CHIPPumpConfigurationAndControlSpeedAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlSpeedAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlSpeedAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlSpeedAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + class CHIPPumpConfigurationAndControlLifetimeRunningHoursAttributeCallback : public chip::Callback::Callback { @@ -6459,6 +6909,36 @@ class CHIPPumpConfigurationAndControlLifetimeRunningHoursAttributeCallback bool keepAlive; }; +class CHIPPumpConfigurationAndControlPowerAttributeCallback + : public chip::Callback::Callback +{ +public: + CHIPPumpConfigurationAndControlPowerAttributeCallback(jobject javaCallback, bool keepAlive = false); + + ~CHIPPumpConfigurationAndControlPowerAttributeCallback(); + + static void maybeDestroy(CHIPPumpConfigurationAndControlPowerAttributeCallback * callback) + { + if (!callback->keepAlive) + { + callback->Cancel(); + chip::Platform::Delete(callback); + } + } + + static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value); + static void OnSubscriptionEstablished(void * context) + { + CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished( + reinterpret_cast(context)->javaCallbackRef); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err))); + }; + +private: + jobject javaCallbackRef; + bool keepAlive; +}; + class CHIPPumpConfigurationAndControlLifetimeEnergyConsumedAttributeCallback : public chip::Callback::Callback { diff --git a/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java b/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java index 0e573acca23b2b..14913dc8bedcd9 100644 --- a/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java +++ b/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java @@ -14078,6 +14078,126 @@ public PumpConfigurationAndControlCluster(long devicePtr, int endpointId) { @Override public native long initWithDevice(long devicePtr, int endpointId); + public interface MaxPressureAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface MaxSpeedAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface MaxFlowAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface MinConstPressureAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface MaxConstPressureAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface MinCompPressureAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface MaxCompPressureAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface MinConstSpeedAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface MaxConstSpeedAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface MinConstFlowAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface MaxConstFlowAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface MinConstTempAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface MaxConstTempAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface CapacityAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + + public interface SpeedAttributeCallback { + void onSuccess(@Nullable Integer value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + public interface LifetimeRunningHoursAttributeCallback { void onSuccess(@Nullable Long value); @@ -14086,6 +14206,14 @@ public interface LifetimeRunningHoursAttributeCallback { default void onSubscriptionEstablished() {} } + public interface PowerAttributeCallback { + void onSuccess(@Nullable Long value); + + void onError(Exception ex); + + default void onSubscriptionEstablished() {} + } + public interface LifetimeEnergyConsumedAttributeCallback { void onSuccess(@Nullable Long value); @@ -14118,120 +14246,120 @@ public interface AttributeListAttributeCallback { default void onSubscriptionEstablished() {} } - public void readMaxPressureAttribute(IntegerAttributeCallback callback) { + public void readMaxPressureAttribute(MaxPressureAttributeCallback callback) { readMaxPressureAttribute(chipClusterPtr, callback); } public void subscribeMaxPressureAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + MaxPressureAttributeCallback callback, int minInterval, int maxInterval) { subscribeMaxPressureAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readMaxSpeedAttribute(IntegerAttributeCallback callback) { + public void readMaxSpeedAttribute(MaxSpeedAttributeCallback callback) { readMaxSpeedAttribute(chipClusterPtr, callback); } public void subscribeMaxSpeedAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + MaxSpeedAttributeCallback callback, int minInterval, int maxInterval) { subscribeMaxSpeedAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readMaxFlowAttribute(IntegerAttributeCallback callback) { + public void readMaxFlowAttribute(MaxFlowAttributeCallback callback) { readMaxFlowAttribute(chipClusterPtr, callback); } public void subscribeMaxFlowAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + MaxFlowAttributeCallback callback, int minInterval, int maxInterval) { subscribeMaxFlowAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readMinConstPressureAttribute(IntegerAttributeCallback callback) { + public void readMinConstPressureAttribute(MinConstPressureAttributeCallback callback) { readMinConstPressureAttribute(chipClusterPtr, callback); } public void subscribeMinConstPressureAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + MinConstPressureAttributeCallback callback, int minInterval, int maxInterval) { subscribeMinConstPressureAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readMaxConstPressureAttribute(IntegerAttributeCallback callback) { + public void readMaxConstPressureAttribute(MaxConstPressureAttributeCallback callback) { readMaxConstPressureAttribute(chipClusterPtr, callback); } public void subscribeMaxConstPressureAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + MaxConstPressureAttributeCallback callback, int minInterval, int maxInterval) { subscribeMaxConstPressureAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readMinCompPressureAttribute(IntegerAttributeCallback callback) { + public void readMinCompPressureAttribute(MinCompPressureAttributeCallback callback) { readMinCompPressureAttribute(chipClusterPtr, callback); } public void subscribeMinCompPressureAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + MinCompPressureAttributeCallback callback, int minInterval, int maxInterval) { subscribeMinCompPressureAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readMaxCompPressureAttribute(IntegerAttributeCallback callback) { + public void readMaxCompPressureAttribute(MaxCompPressureAttributeCallback callback) { readMaxCompPressureAttribute(chipClusterPtr, callback); } public void subscribeMaxCompPressureAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + MaxCompPressureAttributeCallback callback, int minInterval, int maxInterval) { subscribeMaxCompPressureAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readMinConstSpeedAttribute(IntegerAttributeCallback callback) { + public void readMinConstSpeedAttribute(MinConstSpeedAttributeCallback callback) { readMinConstSpeedAttribute(chipClusterPtr, callback); } public void subscribeMinConstSpeedAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + MinConstSpeedAttributeCallback callback, int minInterval, int maxInterval) { subscribeMinConstSpeedAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readMaxConstSpeedAttribute(IntegerAttributeCallback callback) { + public void readMaxConstSpeedAttribute(MaxConstSpeedAttributeCallback callback) { readMaxConstSpeedAttribute(chipClusterPtr, callback); } public void subscribeMaxConstSpeedAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + MaxConstSpeedAttributeCallback callback, int minInterval, int maxInterval) { subscribeMaxConstSpeedAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readMinConstFlowAttribute(IntegerAttributeCallback callback) { + public void readMinConstFlowAttribute(MinConstFlowAttributeCallback callback) { readMinConstFlowAttribute(chipClusterPtr, callback); } public void subscribeMinConstFlowAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + MinConstFlowAttributeCallback callback, int minInterval, int maxInterval) { subscribeMinConstFlowAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readMaxConstFlowAttribute(IntegerAttributeCallback callback) { + public void readMaxConstFlowAttribute(MaxConstFlowAttributeCallback callback) { readMaxConstFlowAttribute(chipClusterPtr, callback); } public void subscribeMaxConstFlowAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + MaxConstFlowAttributeCallback callback, int minInterval, int maxInterval) { subscribeMaxConstFlowAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readMinConstTempAttribute(IntegerAttributeCallback callback) { + public void readMinConstTempAttribute(MinConstTempAttributeCallback callback) { readMinConstTempAttribute(chipClusterPtr, callback); } public void subscribeMinConstTempAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + MinConstTempAttributeCallback callback, int minInterval, int maxInterval) { subscribeMinConstTempAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readMaxConstTempAttribute(IntegerAttributeCallback callback) { + public void readMaxConstTempAttribute(MaxConstTempAttributeCallback callback) { readMaxConstTempAttribute(chipClusterPtr, callback); } public void subscribeMaxConstTempAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + MaxConstTempAttributeCallback callback, int minInterval, int maxInterval) { subscribeMaxConstTempAttribute(chipClusterPtr, callback, minInterval, maxInterval); } @@ -14262,21 +14390,21 @@ public void subscribeEffectiveControlModeAttribute( subscribeEffectiveControlModeAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readCapacityAttribute(IntegerAttributeCallback callback) { + public void readCapacityAttribute(CapacityAttributeCallback callback) { readCapacityAttribute(chipClusterPtr, callback); } public void subscribeCapacityAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + CapacityAttributeCallback callback, int minInterval, int maxInterval) { subscribeCapacityAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readSpeedAttribute(IntegerAttributeCallback callback) { + public void readSpeedAttribute(SpeedAttributeCallback callback) { readSpeedAttribute(chipClusterPtr, callback); } public void subscribeSpeedAttribute( - IntegerAttributeCallback callback, int minInterval, int maxInterval) { + SpeedAttributeCallback callback, int minInterval, int maxInterval) { subscribeSpeedAttribute(chipClusterPtr, callback, minInterval, maxInterval); } @@ -14298,12 +14426,12 @@ public void subscribeLifetimeRunningHoursAttribute( subscribeLifetimeRunningHoursAttribute(chipClusterPtr, callback, minInterval, maxInterval); } - public void readPowerAttribute(LongAttributeCallback callback) { + public void readPowerAttribute(PowerAttributeCallback callback) { readPowerAttribute(chipClusterPtr, callback); } public void subscribePowerAttribute( - LongAttributeCallback callback, int minInterval, int maxInterval) { + PowerAttributeCallback callback, int minInterval, int maxInterval) { subscribePowerAttribute(chipClusterPtr, callback, minInterval, maxInterval); } @@ -14417,82 +14545,115 @@ public void subscribeClusterRevisionAttribute( } private native void readMaxPressureAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, MaxPressureAttributeCallback callback); private native void subscribeMaxPressureAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, + MaxPressureAttributeCallback callback, + int minInterval, + int maxInterval); private native void readMaxSpeedAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, MaxSpeedAttributeCallback callback); private native void subscribeMaxSpeedAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, MaxSpeedAttributeCallback callback, int minInterval, int maxInterval); private native void readMaxFlowAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, MaxFlowAttributeCallback callback); private native void subscribeMaxFlowAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, MaxFlowAttributeCallback callback, int minInterval, int maxInterval); private native void readMinConstPressureAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, MinConstPressureAttributeCallback callback); private native void subscribeMinConstPressureAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, + MinConstPressureAttributeCallback callback, + int minInterval, + int maxInterval); private native void readMaxConstPressureAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, MaxConstPressureAttributeCallback callback); private native void subscribeMaxConstPressureAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, + MaxConstPressureAttributeCallback callback, + int minInterval, + int maxInterval); private native void readMinCompPressureAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, MinCompPressureAttributeCallback callback); private native void subscribeMinCompPressureAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, + MinCompPressureAttributeCallback callback, + int minInterval, + int maxInterval); private native void readMaxCompPressureAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, MaxCompPressureAttributeCallback callback); private native void subscribeMaxCompPressureAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, + MaxCompPressureAttributeCallback callback, + int minInterval, + int maxInterval); private native void readMinConstSpeedAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, MinConstSpeedAttributeCallback callback); private native void subscribeMinConstSpeedAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, + MinConstSpeedAttributeCallback callback, + int minInterval, + int maxInterval); private native void readMaxConstSpeedAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, MaxConstSpeedAttributeCallback callback); private native void subscribeMaxConstSpeedAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, + MaxConstSpeedAttributeCallback callback, + int minInterval, + int maxInterval); private native void readMinConstFlowAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, MinConstFlowAttributeCallback callback); private native void subscribeMinConstFlowAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, + MinConstFlowAttributeCallback callback, + int minInterval, + int maxInterval); private native void readMaxConstFlowAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, MaxConstFlowAttributeCallback callback); private native void subscribeMaxConstFlowAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, + MaxConstFlowAttributeCallback callback, + int minInterval, + int maxInterval); private native void readMinConstTempAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, MinConstTempAttributeCallback callback); private native void subscribeMinConstTempAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, + MinConstTempAttributeCallback callback, + int minInterval, + int maxInterval); private native void readMaxConstTempAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, MaxConstTempAttributeCallback callback); private native void subscribeMaxConstTempAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, + MaxConstTempAttributeCallback callback, + int minInterval, + int maxInterval); private native void readPumpStatusAttribute( long chipClusterPtr, IntegerAttributeCallback callback); @@ -14513,15 +14674,15 @@ private native void subscribeEffectiveControlModeAttribute( long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); private native void readCapacityAttribute( - long chipClusterPtr, IntegerAttributeCallback callback); + long chipClusterPtr, CapacityAttributeCallback callback); private native void subscribeCapacityAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, CapacityAttributeCallback callback, int minInterval, int maxInterval); - private native void readSpeedAttribute(long chipClusterPtr, IntegerAttributeCallback callback); + private native void readSpeedAttribute(long chipClusterPtr, SpeedAttributeCallback callback); private native void subscribeSpeedAttribute( - long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, SpeedAttributeCallback callback, int minInterval, int maxInterval); private native void readLifetimeRunningHoursAttribute( long chipClusterPtr, LifetimeRunningHoursAttributeCallback callback); @@ -14538,10 +14699,10 @@ private native void subscribeLifetimeRunningHoursAttribute( int minInterval, int maxInterval); - private native void readPowerAttribute(long chipClusterPtr, LongAttributeCallback callback); + private native void readPowerAttribute(long chipClusterPtr, PowerAttributeCallback callback); private native void subscribePowerAttribute( - long chipClusterPtr, LongAttributeCallback callback, int minInterval, int maxInterval); + long chipClusterPtr, PowerAttributeCallback callback, int minInterval, int maxInterval); private native void readLifetimeEnergyConsumedAttribute( long chipClusterPtr, LifetimeEnergyConsumedAttributeCallback callback); diff --git a/src/controller/java/zap-generated/chip/devicecontroller/ClusterReadMapping.java b/src/controller/java/zap-generated/chip/devicecontroller/ClusterReadMapping.java index 64d99ba494dcd7..40908164fabdf4 100644 --- a/src/controller/java/zap-generated/chip/devicecontroller/ClusterReadMapping.java +++ b/src/controller/java/zap-generated/chip/devicecontroller/ClusterReadMapping.java @@ -6594,7 +6594,9 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readMaxPressureAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readMaxPressureAttribute( + (ChipClusters.PumpConfigurationAndControlCluster.MaxPressureAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlMaxPressureCommandParams); @@ -6607,7 +6609,9 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readMaxSpeedAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readMaxSpeedAttribute( + (ChipClusters.PumpConfigurationAndControlCluster.MaxSpeedAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlMaxSpeedCommandParams); @@ -6619,7 +6623,9 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readMaxFlowAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readMaxFlowAttribute( + (ChipClusters.PumpConfigurationAndControlCluster.MaxFlowAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlMaxFlowCommandParams); @@ -6631,7 +6637,10 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readMinConstPressureAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readMinConstPressureAttribute( + (ChipClusters.PumpConfigurationAndControlCluster + .MinConstPressureAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlMinConstPressureCommandParams); @@ -6644,7 +6653,10 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readMaxConstPressureAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readMaxConstPressureAttribute( + (ChipClusters.PumpConfigurationAndControlCluster + .MaxConstPressureAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlMaxConstPressureCommandParams); @@ -6657,7 +6669,10 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readMinCompPressureAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readMinCompPressureAttribute( + (ChipClusters.PumpConfigurationAndControlCluster + .MinCompPressureAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlMinCompPressureCommandParams); @@ -6670,7 +6685,10 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readMaxCompPressureAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readMaxCompPressureAttribute( + (ChipClusters.PumpConfigurationAndControlCluster + .MaxCompPressureAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlMaxCompPressureCommandParams); @@ -6683,7 +6701,10 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readMinConstSpeedAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readMinConstSpeedAttribute( + (ChipClusters.PumpConfigurationAndControlCluster + .MinConstSpeedAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlMinConstSpeedCommandParams); @@ -6696,7 +6717,10 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readMaxConstSpeedAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readMaxConstSpeedAttribute( + (ChipClusters.PumpConfigurationAndControlCluster + .MaxConstSpeedAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlMaxConstSpeedCommandParams); @@ -6709,7 +6733,10 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readMinConstFlowAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readMinConstFlowAttribute( + (ChipClusters.PumpConfigurationAndControlCluster + .MinConstFlowAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlMinConstFlowCommandParams); @@ -6722,7 +6749,10 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readMaxConstFlowAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readMaxConstFlowAttribute( + (ChipClusters.PumpConfigurationAndControlCluster + .MaxConstFlowAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlMaxConstFlowCommandParams); @@ -6735,7 +6765,10 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readMinConstTempAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readMinConstTempAttribute( + (ChipClusters.PumpConfigurationAndControlCluster + .MinConstTempAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlMinConstTempCommandParams); @@ -6748,7 +6781,10 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readMaxConstTempAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readMaxConstTempAttribute( + (ChipClusters.PumpConfigurationAndControlCluster + .MaxConstTempAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlMaxConstTempCommandParams); @@ -6804,7 +6840,9 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readCapacityAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readCapacityAttribute( + (ChipClusters.PumpConfigurationAndControlCluster.CapacityAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlCapacityCommandParams); @@ -6816,7 +6854,9 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readSpeedAttribute((ChipClusters.IntegerAttributeCallback) callback); + .readSpeedAttribute( + (ChipClusters.PumpConfigurationAndControlCluster.SpeedAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(), readPumpConfigurationAndControlSpeedCommandParams); @@ -6845,7 +6885,9 @@ public Map> getReadAttributeMap() { new InteractionInfo( (cluster, callback, commandArguments) -> { ((ChipClusters.PumpConfigurationAndControlCluster) cluster) - .readPowerAttribute((ChipClusters.LongAttributeCallback) callback); + .readPowerAttribute( + (ChipClusters.PumpConfigurationAndControlCluster.PowerAttributeCallback) + callback); }, () -> new ClusterInfoMapping.DelegatedLongAttributeCallback(), readPumpConfigurationAndControlPowerCommandParams); diff --git a/src/controller/python/chip/clusters/Objects.py b/src/controller/python/chip/clusters/Objects.py index 2fdcf4fee2e416..4cc97f920e2032 100644 --- a/src/controller/python/chip/clusters/Objects.py +++ b/src/controller/python/chip/clusters/Objects.py @@ -19251,29 +19251,29 @@ class PumpConfigurationAndControl(Cluster): def descriptor(cls) -> ClusterObjectDescriptor: return ClusterObjectDescriptor( Fields = [ - ClusterObjectFieldDescriptor(Label="maxPressure", Tag=0x00000000, Type=int), - ClusterObjectFieldDescriptor(Label="maxSpeed", Tag=0x00000001, Type=uint), - ClusterObjectFieldDescriptor(Label="maxFlow", Tag=0x00000002, Type=uint), - ClusterObjectFieldDescriptor(Label="minConstPressure", Tag=0x00000003, Type=typing.Optional[int]), - ClusterObjectFieldDescriptor(Label="maxConstPressure", Tag=0x00000004, Type=typing.Optional[int]), - ClusterObjectFieldDescriptor(Label="minCompPressure", Tag=0x00000005, Type=typing.Optional[int]), - ClusterObjectFieldDescriptor(Label="maxCompPressure", Tag=0x00000006, Type=typing.Optional[int]), - ClusterObjectFieldDescriptor(Label="minConstSpeed", Tag=0x00000007, Type=typing.Optional[uint]), - ClusterObjectFieldDescriptor(Label="maxConstSpeed", Tag=0x00000008, Type=typing.Optional[uint]), - ClusterObjectFieldDescriptor(Label="minConstFlow", Tag=0x00000009, Type=typing.Optional[uint]), - ClusterObjectFieldDescriptor(Label="maxConstFlow", Tag=0x0000000A, Type=typing.Optional[uint]), - ClusterObjectFieldDescriptor(Label="minConstTemp", Tag=0x0000000B, Type=typing.Optional[int]), - ClusterObjectFieldDescriptor(Label="maxConstTemp", Tag=0x0000000C, Type=typing.Optional[int]), + ClusterObjectFieldDescriptor(Label="maxPressure", Tag=0x00000000, Type=typing.Union[Nullable, int]), + ClusterObjectFieldDescriptor(Label="maxSpeed", Tag=0x00000001, Type=typing.Union[Nullable, uint]), + ClusterObjectFieldDescriptor(Label="maxFlow", Tag=0x00000002, Type=typing.Union[Nullable, uint]), + ClusterObjectFieldDescriptor(Label="minConstPressure", Tag=0x00000003, Type=typing.Union[None, Nullable, int]), + ClusterObjectFieldDescriptor(Label="maxConstPressure", Tag=0x00000004, Type=typing.Union[None, Nullable, int]), + ClusterObjectFieldDescriptor(Label="minCompPressure", Tag=0x00000005, Type=typing.Union[None, Nullable, int]), + ClusterObjectFieldDescriptor(Label="maxCompPressure", Tag=0x00000006, Type=typing.Union[None, Nullable, int]), + ClusterObjectFieldDescriptor(Label="minConstSpeed", Tag=0x00000007, Type=typing.Union[None, Nullable, uint]), + ClusterObjectFieldDescriptor(Label="maxConstSpeed", Tag=0x00000008, Type=typing.Union[None, Nullable, uint]), + ClusterObjectFieldDescriptor(Label="minConstFlow", Tag=0x00000009, Type=typing.Union[None, Nullable, uint]), + ClusterObjectFieldDescriptor(Label="maxConstFlow", Tag=0x0000000A, Type=typing.Union[None, Nullable, uint]), + ClusterObjectFieldDescriptor(Label="minConstTemp", Tag=0x0000000B, Type=typing.Union[None, Nullable, int]), + ClusterObjectFieldDescriptor(Label="maxConstTemp", Tag=0x0000000C, Type=typing.Union[None, Nullable, int]), ClusterObjectFieldDescriptor(Label="pumpStatus", Tag=0x00000010, Type=typing.Optional[uint]), - ClusterObjectFieldDescriptor(Label="effectiveOperationMode", Tag=0x00000011, Type=uint), - ClusterObjectFieldDescriptor(Label="effectiveControlMode", Tag=0x00000012, Type=uint), - ClusterObjectFieldDescriptor(Label="capacity", Tag=0x00000013, Type=int), - ClusterObjectFieldDescriptor(Label="speed", Tag=0x00000014, Type=typing.Optional[uint]), + ClusterObjectFieldDescriptor(Label="effectiveOperationMode", Tag=0x00000011, Type=PumpConfigurationAndControl.Enums.PumpOperationMode), + ClusterObjectFieldDescriptor(Label="effectiveControlMode", Tag=0x00000012, Type=PumpConfigurationAndControl.Enums.PumpControlMode), + ClusterObjectFieldDescriptor(Label="capacity", Tag=0x00000013, Type=typing.Union[Nullable, int]), + ClusterObjectFieldDescriptor(Label="speed", Tag=0x00000014, Type=typing.Union[None, Nullable, uint]), ClusterObjectFieldDescriptor(Label="lifetimeRunningHours", Tag=0x00000015, Type=typing.Union[None, Nullable, uint]), - ClusterObjectFieldDescriptor(Label="power", Tag=0x00000016, Type=typing.Optional[uint]), + ClusterObjectFieldDescriptor(Label="power", Tag=0x00000016, Type=typing.Union[None, Nullable, uint]), ClusterObjectFieldDescriptor(Label="lifetimeEnergyConsumed", Tag=0x00000017, Type=typing.Union[None, Nullable, uint]), - ClusterObjectFieldDescriptor(Label="operationMode", Tag=0x00000020, Type=uint), - ClusterObjectFieldDescriptor(Label="controlMode", Tag=0x00000021, Type=typing.Optional[uint]), + ClusterObjectFieldDescriptor(Label="operationMode", Tag=0x00000020, Type=PumpConfigurationAndControl.Enums.PumpOperationMode), + ClusterObjectFieldDescriptor(Label="controlMode", Tag=0x00000021, Type=typing.Optional[PumpConfigurationAndControl.Enums.PumpControlMode]), ClusterObjectFieldDescriptor(Label="alarmMask", Tag=0x00000022, Type=typing.Optional[uint]), ClusterObjectFieldDescriptor(Label="generatedCommandList", Tag=0x0000FFF8, Type=typing.List[uint]), ClusterObjectFieldDescriptor(Label="acceptedCommandList", Tag=0x0000FFF9, Type=typing.List[uint]), @@ -19282,29 +19282,29 @@ def descriptor(cls) -> ClusterObjectDescriptor: ClusterObjectFieldDescriptor(Label="clusterRevision", Tag=0x0000FFFD, Type=uint), ]) - maxPressure: 'int' = None - maxSpeed: 'uint' = None - maxFlow: 'uint' = None - minConstPressure: 'typing.Optional[int]' = None - maxConstPressure: 'typing.Optional[int]' = None - minCompPressure: 'typing.Optional[int]' = None - maxCompPressure: 'typing.Optional[int]' = None - minConstSpeed: 'typing.Optional[uint]' = None - maxConstSpeed: 'typing.Optional[uint]' = None - minConstFlow: 'typing.Optional[uint]' = None - maxConstFlow: 'typing.Optional[uint]' = None - minConstTemp: 'typing.Optional[int]' = None - maxConstTemp: 'typing.Optional[int]' = None + maxPressure: 'typing.Union[Nullable, int]' = None + maxSpeed: 'typing.Union[Nullable, uint]' = None + maxFlow: 'typing.Union[Nullable, uint]' = None + minConstPressure: 'typing.Union[None, Nullable, int]' = None + maxConstPressure: 'typing.Union[None, Nullable, int]' = None + minCompPressure: 'typing.Union[None, Nullable, int]' = None + maxCompPressure: 'typing.Union[None, Nullable, int]' = None + minConstSpeed: 'typing.Union[None, Nullable, uint]' = None + maxConstSpeed: 'typing.Union[None, Nullable, uint]' = None + minConstFlow: 'typing.Union[None, Nullable, uint]' = None + maxConstFlow: 'typing.Union[None, Nullable, uint]' = None + minConstTemp: 'typing.Union[None, Nullable, int]' = None + maxConstTemp: 'typing.Union[None, Nullable, int]' = None pumpStatus: 'typing.Optional[uint]' = None - effectiveOperationMode: 'uint' = None - effectiveControlMode: 'uint' = None - capacity: 'int' = None - speed: 'typing.Optional[uint]' = None + effectiveOperationMode: 'PumpConfigurationAndControl.Enums.PumpOperationMode' = None + effectiveControlMode: 'PumpConfigurationAndControl.Enums.PumpControlMode' = None + capacity: 'typing.Union[Nullable, int]' = None + speed: 'typing.Union[None, Nullable, uint]' = None lifetimeRunningHours: 'typing.Union[None, Nullable, uint]' = None - power: 'typing.Optional[uint]' = None + power: 'typing.Union[None, Nullable, uint]' = None lifetimeEnergyConsumed: 'typing.Union[None, Nullable, uint]' = None - operationMode: 'uint' = None - controlMode: 'typing.Optional[uint]' = None + operationMode: 'PumpConfigurationAndControl.Enums.PumpOperationMode' = None + controlMode: 'typing.Optional[PumpConfigurationAndControl.Enums.PumpControlMode]' = None alarmMask: 'typing.Optional[uint]' = None generatedCommandList: 'typing.List[uint]' = None acceptedCommandList: 'typing.List[uint]' = None @@ -19343,9 +19343,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=int) + return ClusterObjectFieldDescriptor(Type=typing.Union[Nullable, int]) - value: 'int' = 0 + value: 'typing.Union[Nullable, int]' = NullValue @dataclass class MaxSpeed(ClusterAttributeDescriptor): @@ -19359,9 +19359,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=uint) + return ClusterObjectFieldDescriptor(Type=typing.Union[Nullable, uint]) - value: 'uint' = 0 + value: 'typing.Union[Nullable, uint]' = NullValue @dataclass class MaxFlow(ClusterAttributeDescriptor): @@ -19375,9 +19375,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=uint) + return ClusterObjectFieldDescriptor(Type=typing.Union[Nullable, uint]) - value: 'uint' = 0 + value: 'typing.Union[Nullable, uint]' = NullValue @dataclass class MinConstPressure(ClusterAttributeDescriptor): @@ -19391,9 +19391,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=typing.Optional[int]) + return ClusterObjectFieldDescriptor(Type=typing.Union[None, Nullable, int]) - value: 'typing.Optional[int]' = None + value: 'typing.Union[None, Nullable, int]' = None @dataclass class MaxConstPressure(ClusterAttributeDescriptor): @@ -19407,9 +19407,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=typing.Optional[int]) + return ClusterObjectFieldDescriptor(Type=typing.Union[None, Nullable, int]) - value: 'typing.Optional[int]' = None + value: 'typing.Union[None, Nullable, int]' = None @dataclass class MinCompPressure(ClusterAttributeDescriptor): @@ -19423,9 +19423,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=typing.Optional[int]) + return ClusterObjectFieldDescriptor(Type=typing.Union[None, Nullable, int]) - value: 'typing.Optional[int]' = None + value: 'typing.Union[None, Nullable, int]' = None @dataclass class MaxCompPressure(ClusterAttributeDescriptor): @@ -19439,9 +19439,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=typing.Optional[int]) + return ClusterObjectFieldDescriptor(Type=typing.Union[None, Nullable, int]) - value: 'typing.Optional[int]' = None + value: 'typing.Union[None, Nullable, int]' = None @dataclass class MinConstSpeed(ClusterAttributeDescriptor): @@ -19455,9 +19455,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=typing.Optional[uint]) + return ClusterObjectFieldDescriptor(Type=typing.Union[None, Nullable, uint]) - value: 'typing.Optional[uint]' = None + value: 'typing.Union[None, Nullable, uint]' = None @dataclass class MaxConstSpeed(ClusterAttributeDescriptor): @@ -19471,9 +19471,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=typing.Optional[uint]) + return ClusterObjectFieldDescriptor(Type=typing.Union[None, Nullable, uint]) - value: 'typing.Optional[uint]' = None + value: 'typing.Union[None, Nullable, uint]' = None @dataclass class MinConstFlow(ClusterAttributeDescriptor): @@ -19487,9 +19487,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=typing.Optional[uint]) + return ClusterObjectFieldDescriptor(Type=typing.Union[None, Nullable, uint]) - value: 'typing.Optional[uint]' = None + value: 'typing.Union[None, Nullable, uint]' = None @dataclass class MaxConstFlow(ClusterAttributeDescriptor): @@ -19503,9 +19503,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=typing.Optional[uint]) + return ClusterObjectFieldDescriptor(Type=typing.Union[None, Nullable, uint]) - value: 'typing.Optional[uint]' = None + value: 'typing.Union[None, Nullable, uint]' = None @dataclass class MinConstTemp(ClusterAttributeDescriptor): @@ -19519,9 +19519,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=typing.Optional[int]) + return ClusterObjectFieldDescriptor(Type=typing.Union[None, Nullable, int]) - value: 'typing.Optional[int]' = None + value: 'typing.Union[None, Nullable, int]' = None @dataclass class MaxConstTemp(ClusterAttributeDescriptor): @@ -19535,9 +19535,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=typing.Optional[int]) + return ClusterObjectFieldDescriptor(Type=typing.Union[None, Nullable, int]) - value: 'typing.Optional[int]' = None + value: 'typing.Union[None, Nullable, int]' = None @dataclass class PumpStatus(ClusterAttributeDescriptor): @@ -19567,9 +19567,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=uint) + return ClusterObjectFieldDescriptor(Type=PumpConfigurationAndControl.Enums.PumpOperationMode) - value: 'uint' = 0 + value: 'PumpConfigurationAndControl.Enums.PumpOperationMode' = 0 @dataclass class EffectiveControlMode(ClusterAttributeDescriptor): @@ -19583,9 +19583,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=uint) + return ClusterObjectFieldDescriptor(Type=PumpConfigurationAndControl.Enums.PumpControlMode) - value: 'uint' = 0 + value: 'PumpConfigurationAndControl.Enums.PumpControlMode' = 0 @dataclass class Capacity(ClusterAttributeDescriptor): @@ -19599,9 +19599,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=int) + return ClusterObjectFieldDescriptor(Type=typing.Union[Nullable, int]) - value: 'int' = 0 + value: 'typing.Union[Nullable, int]' = NullValue @dataclass class Speed(ClusterAttributeDescriptor): @@ -19615,9 +19615,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=typing.Optional[uint]) + return ClusterObjectFieldDescriptor(Type=typing.Union[None, Nullable, uint]) - value: 'typing.Optional[uint]' = None + value: 'typing.Union[None, Nullable, uint]' = None @dataclass class LifetimeRunningHours(ClusterAttributeDescriptor): @@ -19647,9 +19647,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=typing.Optional[uint]) + return ClusterObjectFieldDescriptor(Type=typing.Union[None, Nullable, uint]) - value: 'typing.Optional[uint]' = None + value: 'typing.Union[None, Nullable, uint]' = None @dataclass class LifetimeEnergyConsumed(ClusterAttributeDescriptor): @@ -19679,9 +19679,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=uint) + return ClusterObjectFieldDescriptor(Type=PumpConfigurationAndControl.Enums.PumpOperationMode) - value: 'uint' = 0 + value: 'PumpConfigurationAndControl.Enums.PumpOperationMode' = 0 @dataclass class ControlMode(ClusterAttributeDescriptor): @@ -19695,9 +19695,9 @@ def attribute_id(cls) -> int: @ChipUtility.classproperty def attribute_type(cls) -> ClusterObjectFieldDescriptor: - return ClusterObjectFieldDescriptor(Type=typing.Optional[uint]) + return ClusterObjectFieldDescriptor(Type=typing.Optional[PumpConfigurationAndControl.Enums.PumpControlMode]) - value: 'typing.Optional[uint]' = None + value: 'typing.Optional[PumpConfigurationAndControl.Enums.PumpControlMode]' = None @dataclass class AlarmMask(ClusterAttributeDescriptor): diff --git a/src/darwin/Framework/CHIP/zap-generated/CHIPAttributeTLVValueDecoder.mm b/src/darwin/Framework/CHIP/zap-generated/CHIPAttributeTLVValueDecoder.mm index 60d80530e5f105..0e233497d31bae 100644 --- a/src/darwin/Framework/CHIP/zap-generated/CHIPAttributeTLVValueDecoder.mm +++ b/src/darwin/Framework/CHIP/zap-generated/CHIPAttributeTLVValueDecoder.mm @@ -8546,8 +8546,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithShort:cppValue.Value()]; + } return value; } case Attributes::MaxSpeed::Id: { @@ -8557,8 +8561,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithUnsignedShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithUnsignedShort:cppValue.Value()]; + } return value; } case Attributes::MaxFlow::Id: { @@ -8568,8 +8576,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithUnsignedShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithUnsignedShort:cppValue.Value()]; + } return value; } case Attributes::MinConstPressure::Id: { @@ -8579,8 +8591,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithShort:cppValue.Value()]; + } return value; } case Attributes::MaxConstPressure::Id: { @@ -8590,8 +8606,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithShort:cppValue.Value()]; + } return value; } case Attributes::MinCompPressure::Id: { @@ -8601,8 +8621,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithShort:cppValue.Value()]; + } return value; } case Attributes::MaxCompPressure::Id: { @@ -8612,8 +8636,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithShort:cppValue.Value()]; + } return value; } case Attributes::MinConstSpeed::Id: { @@ -8623,8 +8651,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithUnsignedShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithUnsignedShort:cppValue.Value()]; + } return value; } case Attributes::MaxConstSpeed::Id: { @@ -8634,8 +8666,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithUnsignedShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithUnsignedShort:cppValue.Value()]; + } return value; } case Attributes::MinConstFlow::Id: { @@ -8645,8 +8681,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithUnsignedShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithUnsignedShort:cppValue.Value()]; + } return value; } case Attributes::MaxConstFlow::Id: { @@ -8656,8 +8696,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithUnsignedShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithUnsignedShort:cppValue.Value()]; + } return value; } case Attributes::MinConstTemp::Id: { @@ -8667,8 +8711,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithShort:cppValue.Value()]; + } return value; } case Attributes::MaxConstTemp::Id: { @@ -8678,8 +8726,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithShort:cppValue.Value()]; + } return value; } case Attributes::PumpStatus::Id: { @@ -8701,7 +8753,7 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader return nil; } NSNumber * _Nonnull value; - value = [NSNumber numberWithUnsignedChar:cppValue]; + value = [NSNumber numberWithUnsignedChar:chip::to_underlying(cppValue)]; return value; } case Attributes::EffectiveControlMode::Id: { @@ -8712,7 +8764,7 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader return nil; } NSNumber * _Nonnull value; - value = [NSNumber numberWithUnsignedChar:cppValue]; + value = [NSNumber numberWithUnsignedChar:chip::to_underlying(cppValue)]; return value; } case Attributes::Capacity::Id: { @@ -8722,8 +8774,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithShort:cppValue.Value()]; + } return value; } case Attributes::Speed::Id: { @@ -8733,8 +8789,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithUnsignedShort:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithUnsignedShort:cppValue.Value()]; + } return value; } case Attributes::LifetimeRunningHours::Id: { @@ -8759,8 +8819,12 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader if (*aError != CHIP_NO_ERROR) { return nil; } - NSNumber * _Nonnull value; - value = [NSNumber numberWithUnsignedInt:cppValue]; + NSNumber * _Nullable value; + if (cppValue.IsNull()) { + value = nil; + } else { + value = [NSNumber numberWithUnsignedInt:cppValue.Value()]; + } return value; } case Attributes::LifetimeEnergyConsumed::Id: { @@ -8786,7 +8850,7 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader return nil; } NSNumber * _Nonnull value; - value = [NSNumber numberWithUnsignedChar:cppValue]; + value = [NSNumber numberWithUnsignedChar:chip::to_underlying(cppValue)]; return value; } case Attributes::ControlMode::Id: { @@ -8797,7 +8861,7 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader return nil; } NSNumber * _Nonnull value; - value = [NSNumber numberWithUnsignedChar:cppValue]; + value = [NSNumber numberWithUnsignedChar:chip::to_underlying(cppValue)]; return value; } case Attributes::AlarmMask::Id: { diff --git a/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.mm b/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.mm index 62392b173656ea..87e2397e7ec94b 100644 --- a/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.mm +++ b/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.mm @@ -33999,12 +33999,13 @@ @implementation CHIPPumpConfigurationAndControl - (void)readAttributeMaxPressureWithCompletionHandler:(void (^)( NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxPressure::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16sAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxPressure::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeMaxPressureWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34013,7 +34014,7 @@ - (void)subscribeAttributeMaxPressureWithMinInterval:(NSNumber * _Nonnull)minInt subscriptionEstablished:(SubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16sAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16sAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34021,11 +34022,11 @@ new CHIPInt16sAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::MaxPressure::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34038,7 +34039,7 @@ + (void)readAttributeMaxPressureWithAttributeCache:(CHIPAttributeCacheContainer completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxPressure::TypeInfo; @@ -34047,7 +34048,7 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -34060,12 +34061,13 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeMaxSpeedWithCompletionHandler:(void (^)( NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxSpeed::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16uAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxSpeed::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeMaxSpeedWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34074,7 +34076,7 @@ - (void)subscribeAttributeMaxSpeedWithMinInterval:(NSNumber * _Nonnull)minInterv subscriptionEstablished:(SubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16uAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16uAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34082,11 +34084,11 @@ new CHIPInt16uAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::MaxSpeed::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34098,7 +34100,7 @@ + (void)readAttributeMaxSpeedWithAttributeCache:(CHIPAttributeCacheContainer *)a queue:(dispatch_queue_t)queue completionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxSpeed::TypeInfo; @@ -34107,7 +34109,7 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -34119,12 +34121,13 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeMaxFlowWithCompletionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxFlow::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16uAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxFlow::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeMaxFlowWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34133,7 +34136,7 @@ - (void)subscribeAttributeMaxFlowWithMinInterval:(NSNumber * _Nonnull)minInterva subscriptionEstablished:(SubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16uAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16uAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34141,11 +34144,11 @@ new CHIPInt16uAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::MaxFlow::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34157,7 +34160,7 @@ + (void)readAttributeMaxFlowWithAttributeCache:(CHIPAttributeCacheContainer *)at queue:(dispatch_queue_t)queue completionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxFlow::TypeInfo; @@ -34166,7 +34169,7 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -34179,12 +34182,13 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeMinConstPressureWithCompletionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstPressure::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16sAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstPressure::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeMinConstPressureWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34194,7 +34198,7 @@ - (void)subscribeAttributeMinConstPressureWithMinInterval:(NSNumber * _Nonnull)m reportHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16sAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16sAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34202,11 +34206,11 @@ new CHIPInt16sAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstPressure::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34219,7 +34223,7 @@ + (void)readAttributeMinConstPressureWithAttributeCache:(CHIPAttributeCacheConta completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstPressure::TypeInfo; @@ -34228,7 +34232,7 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -34241,12 +34245,13 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeMaxConstPressureWithCompletionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstPressure::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16sAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstPressure::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeMaxConstPressureWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34256,7 +34261,7 @@ - (void)subscribeAttributeMaxConstPressureWithMinInterval:(NSNumber * _Nonnull)m reportHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16sAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16sAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34264,11 +34269,11 @@ new CHIPInt16sAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstPressure::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34281,7 +34286,7 @@ + (void)readAttributeMaxConstPressureWithAttributeCache:(CHIPAttributeCacheConta completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstPressure::TypeInfo; @@ -34290,7 +34295,7 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -34303,12 +34308,13 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeMinCompPressureWithCompletionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::MinCompPressure::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16sAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::MinCompPressure::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeMinCompPressureWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34318,7 +34324,7 @@ - (void)subscribeAttributeMinCompPressureWithMinInterval:(NSNumber * _Nonnull)mi reportHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16sAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16sAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34326,11 +34332,11 @@ new CHIPInt16sAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::MinCompPressure::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34343,7 +34349,7 @@ + (void)readAttributeMinCompPressureWithAttributeCache:(CHIPAttributeCacheContai completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::MinCompPressure::TypeInfo; @@ -34352,7 +34358,7 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -34365,12 +34371,13 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeMaxCompPressureWithCompletionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxCompPressure::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16sAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxCompPressure::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeMaxCompPressureWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34380,7 +34387,7 @@ - (void)subscribeAttributeMaxCompPressureWithMinInterval:(NSNumber * _Nonnull)mi reportHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16sAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16sAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34388,11 +34395,11 @@ new CHIPInt16sAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::MaxCompPressure::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34405,7 +34412,7 @@ + (void)readAttributeMaxCompPressureWithAttributeCache:(CHIPAttributeCacheContai completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxCompPressure::TypeInfo; @@ -34414,7 +34421,7 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -34427,12 +34434,13 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeMinConstSpeedWithCompletionHandler:(void (^)( NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstSpeed::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16uAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstSpeed::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeMinConstSpeedWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34442,7 +34450,7 @@ - (void)subscribeAttributeMinConstSpeedWithMinInterval:(NSNumber * _Nonnull)minI reportHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16uAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16uAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34450,11 +34458,11 @@ new CHIPInt16uAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstSpeed::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34467,7 +34475,7 @@ + (void)readAttributeMinConstSpeedWithAttributeCache:(CHIPAttributeCacheContaine completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstSpeed::TypeInfo; @@ -34476,7 +34484,7 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -34489,12 +34497,13 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeMaxConstSpeedWithCompletionHandler:(void (^)( NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstSpeed::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16uAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstSpeed::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeMaxConstSpeedWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34504,7 +34513,7 @@ - (void)subscribeAttributeMaxConstSpeedWithMinInterval:(NSNumber * _Nonnull)minI reportHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16uAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16uAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34512,11 +34521,11 @@ new CHIPInt16uAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstSpeed::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34529,7 +34538,7 @@ + (void)readAttributeMaxConstSpeedWithAttributeCache:(CHIPAttributeCacheContaine completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstSpeed::TypeInfo; @@ -34538,7 +34547,7 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -34551,12 +34560,13 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeMinConstFlowWithCompletionHandler:(void (^)( NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstFlow::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16uAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstFlow::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeMinConstFlowWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34565,7 +34575,7 @@ - (void)subscribeAttributeMinConstFlowWithMinInterval:(NSNumber * _Nonnull)minIn subscriptionEstablished:(SubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16uAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16uAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34573,11 +34583,11 @@ new CHIPInt16uAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstFlow::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34590,7 +34600,7 @@ + (void)readAttributeMinConstFlowWithAttributeCache:(CHIPAttributeCacheContainer completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstFlow::TypeInfo; @@ -34599,7 +34609,7 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -34612,12 +34622,13 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeMaxConstFlowWithCompletionHandler:(void (^)( NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstFlow::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16uAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstFlow::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeMaxConstFlowWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34626,7 +34637,7 @@ - (void)subscribeAttributeMaxConstFlowWithMinInterval:(NSNumber * _Nonnull)minIn subscriptionEstablished:(SubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16uAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16uAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34634,11 +34645,11 @@ new CHIPInt16uAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstFlow::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34651,7 +34662,7 @@ + (void)readAttributeMaxConstFlowWithAttributeCache:(CHIPAttributeCacheContainer completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstFlow::TypeInfo; @@ -34660,7 +34671,7 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -34673,12 +34684,13 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeMinConstTempWithCompletionHandler:(void (^)( NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstTemp::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16sAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstTemp::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeMinConstTempWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34687,7 +34699,7 @@ - (void)subscribeAttributeMinConstTempWithMinInterval:(NSNumber * _Nonnull)minIn subscriptionEstablished:(SubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16sAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16sAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34695,11 +34707,11 @@ new CHIPInt16sAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstTemp::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34712,7 +34724,7 @@ + (void)readAttributeMinConstTempWithAttributeCache:(CHIPAttributeCacheContainer completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstTemp::TypeInfo; @@ -34721,7 +34733,7 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -34734,12 +34746,13 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeMaxConstTempWithCompletionHandler:(void (^)( NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstTemp::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16sAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstTemp::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeMaxConstTempWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34748,7 +34761,7 @@ - (void)subscribeAttributeMaxConstTempWithMinInterval:(NSNumber * _Nonnull)minIn subscriptionEstablished:(SubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16sAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16sAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34756,11 +34769,11 @@ new CHIPInt16sAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstTemp::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34773,7 +34786,7 @@ + (void)readAttributeMaxConstTempWithAttributeCache:(CHIPAttributeCacheContainer completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstTemp::TypeInfo; @@ -34782,7 +34795,7 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -34855,12 +34868,14 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeEffectiveOperationModeWithCompletionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt8uAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveOperationMode::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPPumpConfigurationAndControlClusterPumpOperationModeAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveOperationMode::TypeInfo; + auto successFn + = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeEffectiveOperationModeWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34871,7 +34886,7 @@ - (void)subscribeAttributeEffectiveOperationModeWithMinInterval:(NSNumber * _Non reportHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt8uAttributeCallbackSubscriptionBridge( + new CHIPPumpConfigurationAndControlClusterPumpOperationModeAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34879,11 +34894,13 @@ new CHIPInt8uAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveOperationMode::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn + = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt8uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPPumpConfigurationAndControlClusterPumpOperationModeAttributeCallbackSubscriptionBridge:: + OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34896,34 +34913,37 @@ + (void)readAttributeEffectiveOperationModeWithAttributeCache:(CHIPAttributeCach completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt8uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - if (attributeCacheContainer.cppAttributeCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveOperationMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); - if (err == CHIP_NO_ERROR) { - successFn->mCall(successFn->mContext, value); + new CHIPPumpConfigurationAndControlClusterPumpOperationModeAttributeCallbackBridge( + queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + if (attributeCacheContainer.cppAttributeCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveOperationMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); + auto successFn + = Callback::FromCancelable(success); + if (err == CHIP_NO_ERROR) { + successFn->mCall(successFn->mContext, value); + } + return err; } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEffectiveControlModeWithCompletionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt8uAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveControlMode::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPPumpConfigurationAndControlClusterPumpControlModeAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveControlMode::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeEffectiveControlModeWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34934,7 +34954,7 @@ - (void)subscribeAttributeEffectiveControlModeWithMinInterval:(NSNumber * _Nonnu reportHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt8uAttributeCallbackSubscriptionBridge( + new CHIPPumpConfigurationAndControlClusterPumpControlModeAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -34942,11 +34962,11 @@ new CHIPInt8uAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveControlMode::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt8uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPPumpConfigurationAndControlClusterPumpControlModeAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -34959,34 +34979,37 @@ + (void)readAttributeEffectiveControlModeWithAttributeCache:(CHIPAttributeCacheC completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt8uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - if (attributeCacheContainer.cppAttributeCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveControlMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); - if (err == CHIP_NO_ERROR) { - successFn->mCall(successFn->mContext, value); + new CHIPPumpConfigurationAndControlClusterPumpControlModeAttributeCallbackBridge( + queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + if (attributeCacheContainer.cppAttributeCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveControlMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); + auto successFn + = Callback::FromCancelable(success); + if (err == CHIP_NO_ERROR) { + successFn->mCall(successFn->mContext, value); + } + return err; } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeCapacityWithCompletionHandler:(void (^)( NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::Capacity::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16sAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::Capacity::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeCapacityWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -34995,7 +35018,7 @@ - (void)subscribeAttributeCapacityWithMinInterval:(NSNumber * _Nonnull)minInterv subscriptionEstablished:(SubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16sAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16sAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -35003,11 +35026,11 @@ new CHIPInt16sAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::Capacity::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16sAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -35019,7 +35042,7 @@ + (void)readAttributeCapacityWithAttributeCache:(CHIPAttributeCacheContainer *)a queue:(dispatch_queue_t)queue completionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::Capacity::TypeInfo; @@ -35028,7 +35051,7 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -35040,12 +35063,13 @@ new CHIPInt16sAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s - (void)readAttributeSpeedWithCompletionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::Speed::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt16uAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::Speed::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeSpeedWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -35054,7 +35078,7 @@ - (void)subscribeAttributeSpeedWithMinInterval:(NSNumber * _Nonnull)minInterval subscriptionEstablished:(SubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16uAttributeCallbackSubscriptionBridge( + new CHIPNullableInt16uAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -35062,11 +35086,11 @@ new CHIPInt16uAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::Speed::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -35078,7 +35102,7 @@ + (void)readAttributeSpeedWithAttributeCache:(CHIPAttributeCacheContainer *)attr queue:(dispatch_queue_t)queue completionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::Speed::TypeInfo; @@ -35087,7 +35111,7 @@ new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -35187,12 +35211,13 @@ new CHIPNullableInt32uAttributeCallbackBridge(queue, completionHandler, ^(Cancel - (void)readAttributePowerWithCompletionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt32uAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::Power::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPNullableInt32uAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::Power::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributePowerWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -35201,7 +35226,7 @@ - (void)subscribeAttributePowerWithMinInterval:(NSNumber * _Nonnull)minInterval subscriptionEstablished:(SubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt32uAttributeCallbackSubscriptionBridge( + new CHIPNullableInt32uAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -35209,11 +35234,11 @@ new CHIPInt32uAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::Power::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt32uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPNullableInt32uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -35225,7 +35250,7 @@ + (void)readAttributePowerWithAttributeCache:(CHIPAttributeCacheContainer *)attr queue:(dispatch_queue_t)queue completionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt32uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + new CHIPNullableInt32uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { if (attributeCacheContainer.cppAttributeCache) { chip::app::ConcreteAttributePath path; using TypeInfo = PumpConfigurationAndControl::Attributes::Power::TypeInfo; @@ -35234,7 +35259,7 @@ new CHIPInt32uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * s path.mAttributeId = TypeInfo::GetAttributeId(); TypeInfo::DecodableType value; CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); if (err == CHIP_NO_ERROR) { successFn->mCall(successFn->mContext, value); } @@ -35335,12 +35360,14 @@ new CHIPNullableInt32uAttributeCallbackBridge(queue, completionHandler, ^(Cancel - (void)readAttributeOperationModeWithCompletionHandler:(void (^)( NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt8uAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::OperationMode::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPPumpConfigurationAndControlClusterPumpOperationModeAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::OperationMode::TypeInfo; + auto successFn + = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)writeAttributeOperationModeWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler @@ -35354,7 +35381,7 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::OperationMode::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedCharValue; + cppValue = static_cast>(value.unsignedCharValue); auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); @@ -35368,7 +35395,7 @@ - (void)subscribeAttributeOperationModeWithMinInterval:(NSNumber * _Nonnull)minI reportHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt8uAttributeCallbackSubscriptionBridge( + new CHIPPumpConfigurationAndControlClusterPumpOperationModeAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -35376,11 +35403,13 @@ new CHIPInt8uAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::OperationMode::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn + = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt8uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPPumpConfigurationAndControlClusterPumpOperationModeAttributeCallbackSubscriptionBridge:: + OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -35393,34 +35422,37 @@ + (void)readAttributeOperationModeWithAttributeCache:(CHIPAttributeCacheContaine completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt8uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - if (attributeCacheContainer.cppAttributeCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::OperationMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); - if (err == CHIP_NO_ERROR) { - successFn->mCall(successFn->mContext, value); + new CHIPPumpConfigurationAndControlClusterPumpOperationModeAttributeCallbackBridge( + queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + if (attributeCacheContainer.cppAttributeCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::OperationMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); + auto successFn + = Callback::FromCancelable(success); + if (err == CHIP_NO_ERROR) { + successFn->mCall(successFn->mContext, value); + } + return err; } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeControlModeWithCompletionHandler:(void (^)( NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt8uAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = PumpConfigurationAndControl::Attributes::ControlMode::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPPumpConfigurationAndControlClusterPumpControlModeAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = PumpConfigurationAndControl::Attributes::ControlMode::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)writeAttributeControlModeWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler @@ -35434,7 +35466,7 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::ControlMode::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedCharValue; + cppValue = static_cast>(value.unsignedCharValue); auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); @@ -35447,7 +35479,7 @@ - (void)subscribeAttributeControlModeWithMinInterval:(NSNumber * _Nonnull)minInt subscriptionEstablished:(SubscriptionEstablishedHandler _Nullable)subscriptionEstablishedHandler reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt8uAttributeCallbackSubscriptionBridge( + new CHIPPumpConfigurationAndControlClusterPumpControlModeAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -35455,11 +35487,11 @@ new CHIPInt8uAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = PumpConfigurationAndControl::Attributes::ControlMode::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt8uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPPumpConfigurationAndControlClusterPumpControlModeAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -35472,23 +35504,25 @@ + (void)readAttributeControlModeWithAttributeCache:(CHIPAttributeCacheContainer completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt8uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - if (attributeCacheContainer.cppAttributeCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = PumpConfigurationAndControl::Attributes::ControlMode::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); - if (err == CHIP_NO_ERROR) { - successFn->mCall(successFn->mContext, value); + new CHIPPumpConfigurationAndControlClusterPumpControlModeAttributeCallbackBridge( + queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + if (attributeCacheContainer.cppAttributeCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = PumpConfigurationAndControl::Attributes::ControlMode::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); + auto successFn + = Callback::FromCancelable(success); + if (err == CHIP_NO_ERROR) { + successFn->mCall(successFn->mContext, value); + } + return err; } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeAlarmMaskWithCompletionHandler:(void (^)( diff --git a/src/darwin/Framework/CHIP/zap-generated/CHIPTestClustersObjc.h b/src/darwin/Framework/CHIP/zap-generated/CHIPTestClustersObjc.h index 5f99354bf7c9b4..628ea4f248ea3c 100644 --- a/src/darwin/Framework/CHIP/zap-generated/CHIPTestClustersObjc.h +++ b/src/darwin/Framework/CHIP/zap-generated/CHIPTestClustersObjc.h @@ -899,27 +899,27 @@ NS_ASSUME_NONNULL_BEGIN */ @interface CHIPTestPumpConfigurationAndControl : CHIPPumpConfigurationAndControl -- (void)writeAttributeMaxPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxFlowWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMinConstPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxConstPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMinCompPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxCompPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMinConstSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxConstSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMinConstFlowWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxConstFlowWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMinConstTempWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxConstTempWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxFlowWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMinConstPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxConstPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMinCompPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxCompPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMinConstSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxConstSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMinConstFlowWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxConstFlowWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMinConstTempWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxConstTempWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; - (void)writeAttributePumpStatusWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; - (void)writeAttributeEffectiveOperationModeWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; - (void)writeAttributeEffectiveControlModeWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeCapacityWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributePowerWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeCapacityWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributePowerWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; - (void)writeAttributeAlarmMaskWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; - (void)writeAttributeGeneratedCommandListWithValue:(NSArray * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; - (void)writeAttributeAcceptedCommandListWithValue:(NSArray * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; diff --git a/src/darwin/Framework/CHIP/zap-generated/CHIPTestClustersObjc.mm b/src/darwin/Framework/CHIP/zap-generated/CHIPTestClustersObjc.mm index 8f3d3fbe5d0bcc..6fad430353a2fa 100644 --- a/src/darwin/Framework/CHIP/zap-generated/CHIPTestClustersObjc.mm +++ b/src/darwin/Framework/CHIP/zap-generated/CHIPTestClustersObjc.mm @@ -11773,7 +11773,7 @@ @implementation CHIPTestPumpConfigurationAndControl return &_cppCluster; } -- (void)writeAttributeMaxPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11784,14 +11784,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxPressure::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11802,14 +11807,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxSpeed::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxFlowWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxFlowWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11820,14 +11830,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxFlow::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMinConstPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMinConstPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11838,14 +11853,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstPressure::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxConstPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxConstPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11856,14 +11876,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstPressure::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMinCompPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMinCompPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11874,14 +11899,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MinCompPressure::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxCompPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxCompPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11892,14 +11922,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxCompPressure::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMinConstSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMinConstSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11910,14 +11945,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstSpeed::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxConstSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxConstSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11928,14 +11968,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstSpeed::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMinConstFlowWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMinConstFlowWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11946,14 +11991,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstFlow::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxConstFlowWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxConstFlowWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11964,14 +12014,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstFlow::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMinConstTempWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMinConstTempWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11982,14 +12037,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstTemp::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxConstTempWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxConstTempWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -12000,7 +12060,12 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstTemp::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); @@ -12037,7 +12102,7 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveOperationMode::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedCharValue; + cppValue = static_cast>(value.unsignedCharValue); auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); @@ -12055,14 +12120,14 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveControlMode::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedCharValue; + cppValue = static_cast>(value.unsignedCharValue); auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeCapacityWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeCapacityWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -12073,14 +12138,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::Capacity::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -12091,14 +12161,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::Speed::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributePowerWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributePowerWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -12109,7 +12184,12 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::Power::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedIntValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedIntValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); diff --git a/zzz_generated/all-clusters-app/zap-generated/access.h b/zzz_generated/all-clusters-app/zap-generated/access.h index d65d68d6b1ba59..abfb3c67e5fcf8 100644 --- a/zzz_generated/all-clusters-app/zap-generated/access.h +++ b/zzz_generated/all-clusters-app/zap-generated/access.h @@ -73,6 +73,10 @@ 49, /* Cluster: Network Commissioning, Attribute: LastConnectErrorValue, Privilege: administer */ \ /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: view */ \ 62, /* Cluster: Operational Credentials, Attribute: NOCs, Privilege: administer */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: view */ \ @@ -132,6 +136,10 @@ 7, /* Cluster: Network Commissioning, Attribute: LastConnectErrorValue, Privilege: administer */ \ /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: view */ \ 0, /* Cluster: Operational Credentials, Attribute: NOCs, Privilege: administer */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: view */ \ @@ -191,6 +199,10 @@ kMatterAccessPrivilegeAdminister, /* Cluster: Network Commissioning, Attribute: LastConnectErrorValue, Privilege: administer */ \ /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: view */ \ kMatterAccessPrivilegeAdminister, /* Cluster: Operational Credentials, Attribute: NOCs, Privilege: administer */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: view */ \ @@ -243,6 +255,10 @@ 8, /* Cluster: Level Control, Attribute: start up current level, Privilege: manage */ \ 49, /* Cluster: Network Commissioning, Attribute: InterfaceEnabled, Privilege: administer */ \ 6, /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: manage */ \ 513, /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: manage */ \ 513, /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: manage */ \ 513, /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: manage */ \ @@ -293,6 +309,10 @@ 16384, /* Cluster: Level Control, Attribute: start up current level, Privilege: manage */ \ 4, /* Cluster: Network Commissioning, Attribute: InterfaceEnabled, Privilege: administer */ \ 16387, /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: manage */ \ + 21, /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: manage */ \ + 23, /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: manage */ \ + 32, /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: manage */ \ + 33, /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: manage */ \ 21, /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: manage */ \ 22, /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: manage */ \ 23, /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: manage */ \ @@ -343,6 +363,10 @@ kMatterAccessPrivilegeManage, /* Cluster: Level Control, Attribute: start up current level, Privilege: manage */ \ kMatterAccessPrivilegeAdminister, /* Cluster: Network Commissioning, Attribute: InterfaceEnabled, Privilege: administer */ \ kMatterAccessPrivilegeManage, /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: manage */ \ kMatterAccessPrivilegeManage, /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: manage */ \ kMatterAccessPrivilegeManage, /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: manage */ \ kMatterAccessPrivilegeManage, /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: manage */ \ diff --git a/zzz_generated/all-clusters-app/zap-generated/endpoint_config.h b/zzz_generated/all-clusters-app/zap-generated/endpoint_config.h index ed44a5a51454ef..c888520fa4471a 100644 --- a/zzz_generated/all-clusters-app/zap-generated/endpoint_config.h +++ b/zzz_generated/all-clusters-app/zap-generated/endpoint_config.h @@ -1007,8 +1007,8 @@ { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0xF }, /* Mode */ \ \ /* Endpoint: 1, Cluster: Pump Configuration and Control (server) */ \ - { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0xFE }, /* OperationMode */ \ - { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0xFE }, /* ControlMode */ \ + { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0x3 }, /* OperationMode */ \ + { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0x7 }, /* ControlMode */ \ \ /* Endpoint: 1, Cluster: Thermostat (server) */ \ { (uint16_t) 0x2BC, (uint16_t) 0x954D, (uint16_t) 0x7FFF }, /* min heat setpoint limit */ \ @@ -1579,27 +1579,27 @@ { 0x0000FFFD, ZAP_TYPE(INT16U), 2, 0, ZAP_SIMPLE_DEFAULT(1) }, /* ClusterRevision */ \ \ /* Endpoint: 1, Cluster: Pump Configuration and Control (server) */ \ - { 0x00000000, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxPressure */ \ - { 0x00000001, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxSpeed */ \ - { 0x00000002, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxFlow */ \ - { 0x00000003, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstPressure */ \ - { 0x00000004, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstPressure */ \ - { 0x00000005, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinCompPressure */ \ - { 0x00000006, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxCompPressure */ \ - { 0x00000007, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstSpeed */ \ - { 0x00000008, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstSpeed */ \ - { 0x00000009, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstFlow */ \ - { 0x0000000A, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstFlow */ \ - { 0x0000000B, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstTemp */ \ - { 0x0000000C, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstTemp */ \ - { 0x00000010, ZAP_TYPE(BITMAP16), 2, 0, ZAP_EMPTY_DEFAULT() }, /* PumpStatus */ \ - { 0x00000011, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveOperationMode */ \ - { 0x00000012, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveControlMode */ \ - { 0x00000013, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* Capacity */ \ - { 0x00000014, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* Speed */ \ + { 0x00000000, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxPressure */ \ + { 0x00000001, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxSpeed */ \ + { 0x00000002, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxFlow */ \ + { 0x00000003, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstPressure */ \ + { 0x00000004, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstPressure */ \ + { 0x00000005, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinCompPressure */ \ + { 0x00000006, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxCompPressure */ \ + { 0x00000007, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstSpeed */ \ + { 0x00000008, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstSpeed */ \ + { 0x00000009, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstFlow */ \ + { 0x0000000A, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstFlow */ \ + { 0x0000000B, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstTemp */ \ + { 0x0000000C, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstTemp */ \ + { 0x00000010, ZAP_TYPE(BITMAP16), 2, 0, ZAP_EMPTY_DEFAULT() }, /* PumpStatus */ \ + { 0x00000011, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveOperationMode */ \ + { 0x00000012, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveControlMode */ \ + { 0x00000013, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* Capacity */ \ + { 0x00000014, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* Speed */ \ { 0x00000015, ZAP_TYPE(INT24U), 3, ZAP_ATTRIBUTE_MASK(WRITABLE) | ZAP_ATTRIBUTE_MASK(NULLABLE), \ - ZAP_LONG_DEFAULTS_INDEX(413) }, /* LifetimeRunningHours */ \ - { 0x00000016, ZAP_TYPE(INT24U), 3, 0, ZAP_LONG_DEFAULTS_INDEX(416) }, /* Power */ \ + ZAP_LONG_DEFAULTS_INDEX(413) }, /* LifetimeRunningHours */ \ + { 0x00000016, ZAP_TYPE(INT24U), 3, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_LONG_DEFAULTS_INDEX(416) }, /* Power */ \ { 0x00000017, ZAP_TYPE(INT32U), 4, ZAP_ATTRIBUTE_MASK(WRITABLE) | ZAP_ATTRIBUTE_MASK(NULLABLE), \ ZAP_LONG_DEFAULTS_INDEX(419) }, /* LifetimeEnergyConsumed */ \ { 0x00000020, ZAP_TYPE(ENUM8), 1, ZAP_ATTRIBUTE_MASK(MIN_MAX) | ZAP_ATTRIBUTE_MASK(WRITABLE), \ diff --git a/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.cpp b/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.cpp index 609ea9c85d06cb..ececc02bf5d78c 100644 --- a/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.cpp +++ b/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.cpp @@ -16723,7 +16723,7 @@ namespace Attributes { namespace MaxPressure { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -16731,17 +16731,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -16752,11 +16755,31 @@ EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) ZCL_INT16S_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16S_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace MaxPressure namespace MaxSpeed { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -16764,17 +16787,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -16785,11 +16811,31 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) ZCL_INT16U_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16U_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace MaxSpeed namespace MaxFlow { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -16797,17 +16843,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -16818,11 +16867,31 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) ZCL_INT16U_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16U_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace MaxFlow namespace MinConstPressure { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -16830,17 +16899,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -16851,11 +16923,31 @@ EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) ZCL_INT16S_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16S_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace MinConstPressure namespace MaxConstPressure { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -16863,17 +16955,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -16884,11 +16979,31 @@ EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) ZCL_INT16S_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16S_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace MaxConstPressure namespace MinCompPressure { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -16896,17 +17011,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -16917,11 +17035,31 @@ EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) ZCL_INT16S_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16S_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace MinCompPressure namespace MaxCompPressure { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -16929,17 +17067,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -16950,11 +17091,31 @@ EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) ZCL_INT16S_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16S_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace MaxCompPressure namespace MinConstSpeed { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -16962,17 +17123,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -16983,11 +17147,31 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) ZCL_INT16U_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16U_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace MinConstSpeed namespace MaxConstSpeed { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -16995,32 +17179,55 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) + { + return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + } + Traits::StorageType storageValue; + Traits::WorkingToStorage(value, storageValue); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(storageValue); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16U_ATTRIBUTE_TYPE); +} + +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16U_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + return SetNull(endpoint); } - Traits::StorageType storageValue; - Traits::WorkingToStorage(value, storageValue); - uint8_t * writable = Traits::ToAttributeStoreRepresentation(storageValue); - return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, - ZCL_INT16U_ATTRIBUTE_TYPE); + + return Set(endpoint, value.Value()); } } // namespace MaxConstSpeed namespace MinConstFlow { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -17028,17 +17235,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -17049,11 +17259,31 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) ZCL_INT16U_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16U_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace MinConstFlow namespace MaxConstFlow { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -17061,17 +17291,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -17082,11 +17315,31 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) ZCL_INT16U_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16U_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace MaxConstFlow namespace MinConstTemp { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -17094,17 +17347,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -17115,11 +17371,31 @@ EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) ZCL_INT16S_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16S_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace MinConstTemp namespace MaxConstTemp { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -17127,17 +17403,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -17148,6 +17427,26 @@ EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) ZCL_INT16S_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16S_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace MaxConstTemp namespace PumpStatus { @@ -17185,9 +17484,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) namespace EffectiveOperationMode { -EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = @@ -17200,9 +17499,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -17217,9 +17516,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value) namespace EffectiveControlMode { -EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = @@ -17232,9 +17531,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -17249,7 +17548,7 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value) namespace Capacity { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -17257,17 +17556,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -17278,11 +17580,31 @@ EmberAfStatus Set(chip::EndpointId endpoint, int16_t value) ZCL_INT16S_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16S_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace Capacity namespace Speed { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits; Traits::StorageType temp; @@ -17290,17 +17612,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) { using Traits = NumericAttributeTraits; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -17311,6 +17636,26 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) ZCL_INT16U_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT16U_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace Speed namespace LifetimeRunningHours { @@ -17371,7 +17716,7 @@ EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullabl namespace Power { -EmberAfStatus Get(chip::EndpointId endpoint, uint32_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value) { using Traits = NumericAttributeTraits>; Traits::StorageType temp; @@ -17379,17 +17724,20 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint32_t * value) EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, readable, sizeof(temp)); VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, status); - if (!Traits::CanRepresentValue(/* isNullable = */ false, temp)) + if (Traits::IsNullValue(temp)) { - return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; + value.SetNull(); + } + else + { + value.SetNonNull() = Traits::StorageToWorking(temp); } - *value = Traits::StorageToWorking(temp); return status; } EmberAfStatus Set(chip::EndpointId endpoint, uint32_t value) { using Traits = NumericAttributeTraits>; - if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) + if (!Traits::CanRepresentValue(/* isNullable = */ true, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; } @@ -17400,6 +17748,26 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint32_t value) ZCL_INT24U_ATTRIBUTE_TYPE); } +EmberAfStatus SetNull(chip::EndpointId endpoint) +{ + using Traits = NumericAttributeTraits>; + Traits::StorageType value; + Traits::SetNull(value); + uint8_t * writable = Traits::ToAttributeStoreRepresentation(value); + return emberAfWriteServerAttribute(endpoint, Clusters::PumpConfigurationAndControl::Id, Id, writable, + ZCL_INT24U_ATTRIBUTE_TYPE); +} + +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value) +{ + if (value.IsNull()) + { + return SetNull(endpoint); + } + + return Set(endpoint, value.Value()); +} + } // namespace Power namespace LifetimeEnergyConsumed { @@ -17460,9 +17828,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullabl namespace OperationMode { -EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = @@ -17475,9 +17843,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -17492,9 +17860,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value) namespace ControlMode { -EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = @@ -17507,9 +17875,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; diff --git a/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.h b/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.h index a216278fd4d86f..68d536b8854363 100644 --- a/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.h +++ b/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.h @@ -2969,68 +2969,94 @@ namespace PumpConfigurationAndControl { namespace Attributes { namespace MaxPressure { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value); // int16s +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16s EmberAfStatus Set(chip::EndpointId endpoint, int16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace MaxPressure namespace MaxSpeed { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // int16u +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16u EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace MaxSpeed namespace MaxFlow { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // int16u +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16u EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace MaxFlow namespace MinConstPressure { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value); // int16s +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16s EmberAfStatus Set(chip::EndpointId endpoint, int16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace MinConstPressure namespace MaxConstPressure { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value); // int16s +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16s EmberAfStatus Set(chip::EndpointId endpoint, int16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace MaxConstPressure namespace MinCompPressure { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value); // int16s +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16s EmberAfStatus Set(chip::EndpointId endpoint, int16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace MinCompPressure namespace MaxCompPressure { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value); // int16s +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16s EmberAfStatus Set(chip::EndpointId endpoint, int16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace MaxCompPressure namespace MinConstSpeed { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // int16u +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16u EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace MinConstSpeed namespace MaxConstSpeed { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // int16u +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16u EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace MaxConstSpeed namespace MinConstFlow { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // int16u +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16u EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace MinConstFlow namespace MaxConstFlow { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // int16u +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16u EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace MaxConstFlow namespace MinConstTemp { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value); // int16s +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16s EmberAfStatus Set(chip::EndpointId endpoint, int16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace MinConstTemp namespace MaxConstTemp { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value); // int16s +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16s EmberAfStatus Set(chip::EndpointId endpoint, int16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace MaxConstTemp namespace PumpStatus { @@ -3039,23 +3065,29 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); } // namespace PumpStatus namespace EffectiveOperationMode { -EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value); // enum8 -EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value); +EmberAfStatus Get(chip::EndpointId endpoint, + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode * value); // PumpOperationMode +EmberAfStatus Set(chip::EndpointId endpoint, chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode value); } // namespace EffectiveOperationMode namespace EffectiveControlMode { -EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value); // enum8 -EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value); +EmberAfStatus Get(chip::EndpointId endpoint, + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode * value); // PumpControlMode +EmberAfStatus Set(chip::EndpointId endpoint, chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode value); } // namespace EffectiveControlMode namespace Capacity { -EmberAfStatus Get(chip::EndpointId endpoint, int16_t * value); // int16s +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16s EmberAfStatus Set(chip::EndpointId endpoint, int16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace Capacity namespace Speed { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // int16u +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int16u EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace Speed namespace LifetimeRunningHours { @@ -3066,8 +3098,10 @@ EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullabl } // namespace LifetimeRunningHours namespace Power { -EmberAfStatus Get(chip::EndpointId endpoint, uint32_t * value); // int24u +EmberAfStatus Get(chip::EndpointId endpoint, DataModel::Nullable & value); // int24u EmberAfStatus Set(chip::EndpointId endpoint, uint32_t value); +EmberAfStatus SetNull(chip::EndpointId endpoint); +EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullable & value); } // namespace Power namespace LifetimeEnergyConsumed { @@ -3078,13 +3112,15 @@ EmberAfStatus Set(chip::EndpointId endpoint, const chip::app::DataModel::Nullabl } // namespace LifetimeEnergyConsumed namespace OperationMode { -EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value); // enum8 -EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value); +EmberAfStatus Get(chip::EndpointId endpoint, + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode * value); // PumpOperationMode +EmberAfStatus Set(chip::EndpointId endpoint, chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode value); } // namespace OperationMode namespace ControlMode { -EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value); // enum8 -EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value); +EmberAfStatus Get(chip::EndpointId endpoint, + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode * value); // PumpControlMode +EmberAfStatus Set(chip::EndpointId endpoint, chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode value); } // namespace ControlMode namespace AlarmMask { diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h index dde8ddf8b46984..91d1a3d4646910 100644 --- a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h +++ b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h @@ -21104,9 +21104,9 @@ namespace Attributes { namespace MaxPressure { struct TypeInfo { - using Type = int16_t; - using DecodableType = int16_t; - using DecodableArgType = int16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::MaxPressure::Id; } @@ -21116,9 +21116,9 @@ struct TypeInfo namespace MaxSpeed { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::MaxSpeed::Id; } @@ -21128,9 +21128,9 @@ struct TypeInfo namespace MaxFlow { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::MaxFlow::Id; } @@ -21140,9 +21140,9 @@ struct TypeInfo namespace MinConstPressure { struct TypeInfo { - using Type = int16_t; - using DecodableType = int16_t; - using DecodableArgType = int16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::MinConstPressure::Id; } @@ -21152,9 +21152,9 @@ struct TypeInfo namespace MaxConstPressure { struct TypeInfo { - using Type = int16_t; - using DecodableType = int16_t; - using DecodableArgType = int16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::MaxConstPressure::Id; } @@ -21164,9 +21164,9 @@ struct TypeInfo namespace MinCompPressure { struct TypeInfo { - using Type = int16_t; - using DecodableType = int16_t; - using DecodableArgType = int16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::MinCompPressure::Id; } @@ -21176,9 +21176,9 @@ struct TypeInfo namespace MaxCompPressure { struct TypeInfo { - using Type = int16_t; - using DecodableType = int16_t; - using DecodableArgType = int16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::MaxCompPressure::Id; } @@ -21188,9 +21188,9 @@ struct TypeInfo namespace MinConstSpeed { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::MinConstSpeed::Id; } @@ -21200,9 +21200,9 @@ struct TypeInfo namespace MaxConstSpeed { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::MaxConstSpeed::Id; } @@ -21212,9 +21212,9 @@ struct TypeInfo namespace MinConstFlow { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::MinConstFlow::Id; } @@ -21224,9 +21224,9 @@ struct TypeInfo namespace MaxConstFlow { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::MaxConstFlow::Id; } @@ -21236,9 +21236,9 @@ struct TypeInfo namespace MinConstTemp { struct TypeInfo { - using Type = int16_t; - using DecodableType = int16_t; - using DecodableArgType = int16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::MinConstTemp::Id; } @@ -21248,9 +21248,9 @@ struct TypeInfo namespace MaxConstTemp { struct TypeInfo { - using Type = int16_t; - using DecodableType = int16_t; - using DecodableArgType = int16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::MaxConstTemp::Id; } @@ -21272,9 +21272,9 @@ struct TypeInfo namespace EffectiveOperationMode { struct TypeInfo { - using Type = uint8_t; - using DecodableType = uint8_t; - using DecodableArgType = uint8_t; + using Type = chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode; + using DecodableType = chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode; + using DecodableArgType = chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::EffectiveOperationMode::Id; } @@ -21284,9 +21284,9 @@ struct TypeInfo namespace EffectiveControlMode { struct TypeInfo { - using Type = uint8_t; - using DecodableType = uint8_t; - using DecodableArgType = uint8_t; + using Type = chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode; + using DecodableType = chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode; + using DecodableArgType = chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::EffectiveControlMode::Id; } @@ -21296,9 +21296,9 @@ struct TypeInfo namespace Capacity { struct TypeInfo { - using Type = int16_t; - using DecodableType = int16_t; - using DecodableArgType = int16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::Capacity::Id; } @@ -21308,9 +21308,9 @@ struct TypeInfo namespace Speed { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::Speed::Id; } @@ -21332,9 +21332,9 @@ struct TypeInfo namespace Power { struct TypeInfo { - using Type = uint32_t; - using DecodableType = uint32_t; - using DecodableArgType = uint32_t; + using Type = chip::app::DataModel::Nullable; + using DecodableType = chip::app::DataModel::Nullable; + using DecodableArgType = const chip::app::DataModel::Nullable &; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::Power::Id; } @@ -21356,9 +21356,9 @@ struct TypeInfo namespace OperationMode { struct TypeInfo { - using Type = uint8_t; - using DecodableType = uint8_t; - using DecodableArgType = uint8_t; + using Type = chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode; + using DecodableType = chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode; + using DecodableArgType = chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::OperationMode::Id; } @@ -21368,9 +21368,9 @@ struct TypeInfo namespace ControlMode { struct TypeInfo { - using Type = uint8_t; - using DecodableType = uint8_t; - using DecodableArgType = uint8_t; + using Type = chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode; + using DecodableType = chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode; + using DecodableArgType = chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode; static constexpr ClusterId GetClusterId() { return Clusters::PumpConfigurationAndControl::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::ControlMode::Id; } @@ -21458,30 +21458,34 @@ struct TypeInfo CHIP_ERROR Decode(TLV::TLVReader & reader, const ConcreteAttributePath & path); - Attributes::MaxPressure::TypeInfo::DecodableType maxPressure = static_cast(0); - Attributes::MaxSpeed::TypeInfo::DecodableType maxSpeed = static_cast(0); - Attributes::MaxFlow::TypeInfo::DecodableType maxFlow = static_cast(0); - Attributes::MinConstPressure::TypeInfo::DecodableType minConstPressure = static_cast(0); - Attributes::MaxConstPressure::TypeInfo::DecodableType maxConstPressure = static_cast(0); - Attributes::MinCompPressure::TypeInfo::DecodableType minCompPressure = static_cast(0); - Attributes::MaxCompPressure::TypeInfo::DecodableType maxCompPressure = static_cast(0); - Attributes::MinConstSpeed::TypeInfo::DecodableType minConstSpeed = static_cast(0); - Attributes::MaxConstSpeed::TypeInfo::DecodableType maxConstSpeed = static_cast(0); - Attributes::MinConstFlow::TypeInfo::DecodableType minConstFlow = static_cast(0); - Attributes::MaxConstFlow::TypeInfo::DecodableType maxConstFlow = static_cast(0); - Attributes::MinConstTemp::TypeInfo::DecodableType minConstTemp = static_cast(0); - Attributes::MaxConstTemp::TypeInfo::DecodableType maxConstTemp = static_cast(0); - Attributes::PumpStatus::TypeInfo::DecodableType pumpStatus = static_cast(0); - Attributes::EffectiveOperationMode::TypeInfo::DecodableType effectiveOperationMode = static_cast(0); - Attributes::EffectiveControlMode::TypeInfo::DecodableType effectiveControlMode = static_cast(0); - Attributes::Capacity::TypeInfo::DecodableType capacity = static_cast(0); - Attributes::Speed::TypeInfo::DecodableType speed = static_cast(0); + Attributes::MaxPressure::TypeInfo::DecodableType maxPressure; + Attributes::MaxSpeed::TypeInfo::DecodableType maxSpeed; + Attributes::MaxFlow::TypeInfo::DecodableType maxFlow; + Attributes::MinConstPressure::TypeInfo::DecodableType minConstPressure; + Attributes::MaxConstPressure::TypeInfo::DecodableType maxConstPressure; + Attributes::MinCompPressure::TypeInfo::DecodableType minCompPressure; + Attributes::MaxCompPressure::TypeInfo::DecodableType maxCompPressure; + Attributes::MinConstSpeed::TypeInfo::DecodableType minConstSpeed; + Attributes::MaxConstSpeed::TypeInfo::DecodableType maxConstSpeed; + Attributes::MinConstFlow::TypeInfo::DecodableType minConstFlow; + Attributes::MaxConstFlow::TypeInfo::DecodableType maxConstFlow; + Attributes::MinConstTemp::TypeInfo::DecodableType minConstTemp; + Attributes::MaxConstTemp::TypeInfo::DecodableType maxConstTemp; + Attributes::PumpStatus::TypeInfo::DecodableType pumpStatus = static_cast(0); + Attributes::EffectiveOperationMode::TypeInfo::DecodableType effectiveOperationMode = + static_cast(0); + Attributes::EffectiveControlMode::TypeInfo::DecodableType effectiveControlMode = + static_cast(0); + Attributes::Capacity::TypeInfo::DecodableType capacity; + Attributes::Speed::TypeInfo::DecodableType speed; Attributes::LifetimeRunningHours::TypeInfo::DecodableType lifetimeRunningHours; - Attributes::Power::TypeInfo::DecodableType power = static_cast(0); + Attributes::Power::TypeInfo::DecodableType power; Attributes::LifetimeEnergyConsumed::TypeInfo::DecodableType lifetimeEnergyConsumed; - Attributes::OperationMode::TypeInfo::DecodableType operationMode = static_cast(0); - Attributes::ControlMode::TypeInfo::DecodableType controlMode = static_cast(0); - Attributes::AlarmMask::TypeInfo::DecodableType alarmMask = static_cast(0); + Attributes::OperationMode::TypeInfo::DecodableType operationMode = + static_cast(0); + Attributes::ControlMode::TypeInfo::DecodableType controlMode = + static_cast(0); + Attributes::AlarmMask::TypeInfo::DecodableType alarmMask = static_cast(0); Attributes::GeneratedCommandList::TypeInfo::DecodableType generatedCommandList; Attributes::AcceptedCommandList::TypeInfo::DecodableType acceptedCommandList; Attributes::AttributeList::TypeInfo::DecodableType attributeList; diff --git a/zzz_generated/chip-tool-darwin/zap-generated/cluster/CHIPTestClustersObjc.h b/zzz_generated/chip-tool-darwin/zap-generated/cluster/CHIPTestClustersObjc.h index 5f99354bf7c9b4..628ea4f248ea3c 100644 --- a/zzz_generated/chip-tool-darwin/zap-generated/cluster/CHIPTestClustersObjc.h +++ b/zzz_generated/chip-tool-darwin/zap-generated/cluster/CHIPTestClustersObjc.h @@ -899,27 +899,27 @@ NS_ASSUME_NONNULL_BEGIN */ @interface CHIPTestPumpConfigurationAndControl : CHIPPumpConfigurationAndControl -- (void)writeAttributeMaxPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxFlowWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMinConstPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxConstPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMinCompPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxCompPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMinConstSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxConstSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMinConstFlowWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxConstFlowWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMinConstTempWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeMaxConstTempWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxFlowWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMinConstPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxConstPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMinCompPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxCompPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMinConstSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxConstSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMinConstFlowWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxConstFlowWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMinConstTempWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeMaxConstTempWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; - (void)writeAttributePumpStatusWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; - (void)writeAttributeEffectiveOperationModeWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; - (void)writeAttributeEffectiveControlModeWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeCapacityWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributeSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; -- (void)writeAttributePowerWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeCapacityWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributeSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; +- (void)writeAttributePowerWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler; - (void)writeAttributeAlarmMaskWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; - (void)writeAttributeGeneratedCommandListWithValue:(NSArray * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; - (void)writeAttributeAcceptedCommandListWithValue:(NSArray * _Nonnull)value completionHandler:(StatusCompletion)completionHandler; diff --git a/zzz_generated/chip-tool-darwin/zap-generated/cluster/CHIPTestClustersObjc.mm b/zzz_generated/chip-tool-darwin/zap-generated/cluster/CHIPTestClustersObjc.mm index 8f3d3fbe5d0bcc..6fad430353a2fa 100644 --- a/zzz_generated/chip-tool-darwin/zap-generated/cluster/CHIPTestClustersObjc.mm +++ b/zzz_generated/chip-tool-darwin/zap-generated/cluster/CHIPTestClustersObjc.mm @@ -11773,7 +11773,7 @@ @implementation CHIPTestPumpConfigurationAndControl return &_cppCluster; } -- (void)writeAttributeMaxPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11784,14 +11784,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxPressure::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11802,14 +11807,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxSpeed::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxFlowWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxFlowWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11820,14 +11830,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxFlow::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMinConstPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMinConstPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11838,14 +11853,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstPressure::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxConstPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxConstPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11856,14 +11876,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstPressure::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMinCompPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMinCompPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11874,14 +11899,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MinCompPressure::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxCompPressureWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxCompPressureWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11892,14 +11922,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxCompPressure::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMinConstSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMinConstSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11910,14 +11945,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstSpeed::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxConstSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxConstSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11928,14 +11968,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstSpeed::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMinConstFlowWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMinConstFlowWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11946,14 +11991,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstFlow::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxConstFlowWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxConstFlowWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11964,14 +12014,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstFlow::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMinConstTempWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMinConstTempWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -11982,14 +12037,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MinConstTemp::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeMaxConstTempWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeMaxConstTempWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -12000,7 +12060,12 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::MaxConstTemp::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); @@ -12037,7 +12102,7 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveOperationMode::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedCharValue; + cppValue = static_cast>(value.unsignedCharValue); auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); @@ -12055,14 +12120,14 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::EffectiveControlMode::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedCharValue; + cppValue = static_cast>(value.unsignedCharValue); auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeCapacityWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeCapacityWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -12073,14 +12138,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::Capacity::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.shortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.shortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributeSpeedWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributeSpeedWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -12091,14 +12161,19 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::Speed::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedShortValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); }); } -- (void)writeAttributePowerWithValue:(NSNumber * _Nonnull)value completionHandler:(StatusCompletion)completionHandler +- (void)writeAttributePowerWithValue:(NSNumber * _Nullable)value completionHandler:(StatusCompletion)completionHandler { new CHIPDefaultSuccessCallbackBridge( self.callbackQueue, @@ -12109,7 +12184,12 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = PumpConfigurationAndControl::Attributes::Power::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedIntValue; + if (value == nil) { + cppValue.SetNull(); + } else { + auto & nonNullValue_0 = cppValue.SetNonNull(); + nonNullValue_0 = value.unsignedIntValue; + } auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); diff --git a/zzz_generated/chip-tool/zap-generated/cluster/Commands.h b/zzz_generated/chip-tool/zap-generated/cluster/Commands.h index 00d77b2e2101b3..95ad68cba60651 100644 --- a/zzz_generated/chip-tool/zap-generated/cluster/Commands.h +++ b/zzz_generated/chip-tool/zap-generated/cluster/Commands.h @@ -9818,7 +9818,7 @@ class WritePumpConfigurationAndControlOperationMode : public WriteAttribute } private: - uint8_t mValue; + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode mValue; }; class WritePumpConfigurationAndControlControlMode : public WriteAttribute @@ -9845,7 +9845,7 @@ class WritePumpConfigurationAndControlControlMode : public WriteAttribute } private: - uint8_t mValue; + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode mValue; }; /*----------------------------------------------------------------------------*\ diff --git a/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp b/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp index f5655a4dd20bb7..de128f2c182af9 100644 --- a/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp +++ b/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp @@ -8106,67 +8106,67 @@ CHIP_ERROR DataModelLogger::LogAttribute(const chip::app::ConcreteDataAttributeP switch (path.mAttributeId) { case PumpConfigurationAndControl::Attributes::MaxPressure::Id: { - int16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("MaxPressure", 1, value); } case PumpConfigurationAndControl::Attributes::MaxSpeed::Id: { - uint16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("MaxSpeed", 1, value); } case PumpConfigurationAndControl::Attributes::MaxFlow::Id: { - uint16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("MaxFlow", 1, value); } case PumpConfigurationAndControl::Attributes::MinConstPressure::Id: { - int16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("MinConstPressure", 1, value); } case PumpConfigurationAndControl::Attributes::MaxConstPressure::Id: { - int16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("MaxConstPressure", 1, value); } case PumpConfigurationAndControl::Attributes::MinCompPressure::Id: { - int16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("MinCompPressure", 1, value); } case PumpConfigurationAndControl::Attributes::MaxCompPressure::Id: { - int16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("MaxCompPressure", 1, value); } case PumpConfigurationAndControl::Attributes::MinConstSpeed::Id: { - uint16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("MinConstSpeed", 1, value); } case PumpConfigurationAndControl::Attributes::MaxConstSpeed::Id: { - uint16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("MaxConstSpeed", 1, value); } case PumpConfigurationAndControl::Attributes::MinConstFlow::Id: { - uint16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("MinConstFlow", 1, value); } case PumpConfigurationAndControl::Attributes::MaxConstFlow::Id: { - uint16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("MaxConstFlow", 1, value); } case PumpConfigurationAndControl::Attributes::MinConstTemp::Id: { - int16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("MinConstTemp", 1, value); } case PumpConfigurationAndControl::Attributes::MaxConstTemp::Id: { - int16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("MaxConstTemp", 1, value); } @@ -8176,22 +8176,22 @@ CHIP_ERROR DataModelLogger::LogAttribute(const chip::app::ConcreteDataAttributeP return DataModelLogger::LogValue("PumpStatus", 1, value); } case PumpConfigurationAndControl::Attributes::EffectiveOperationMode::Id: { - uint8_t value; + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("EffectiveOperationMode", 1, value); } case PumpConfigurationAndControl::Attributes::EffectiveControlMode::Id: { - uint8_t value; + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("EffectiveControlMode", 1, value); } case PumpConfigurationAndControl::Attributes::Capacity::Id: { - int16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("Capacity", 1, value); } case PumpConfigurationAndControl::Attributes::Speed::Id: { - uint16_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("Speed", 1, value); } @@ -8201,7 +8201,7 @@ CHIP_ERROR DataModelLogger::LogAttribute(const chip::app::ConcreteDataAttributeP return DataModelLogger::LogValue("LifetimeRunningHours", 1, value); } case PumpConfigurationAndControl::Attributes::Power::Id: { - uint32_t value; + chip::app::DataModel::Nullable value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("Power", 1, value); } @@ -8211,12 +8211,12 @@ CHIP_ERROR DataModelLogger::LogAttribute(const chip::app::ConcreteDataAttributeP return DataModelLogger::LogValue("LifetimeEnergyConsumed", 1, value); } case PumpConfigurationAndControl::Attributes::OperationMode::Id: { - uint8_t value; + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("OperationMode", 1, value); } case PumpConfigurationAndControl::Attributes::ControlMode::Id: { - uint8_t value; + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("ControlMode", 1, value); } diff --git a/zzz_generated/chip-tool/zap-generated/test/Commands.h b/zzz_generated/chip-tool/zap-generated/test/Commands.h index 26c45688db0677..326e09a15b094b 100644 --- a/zzz_generated/chip-tool/zap-generated/test/Commands.h +++ b/zzz_generated/chip-tool/zap-generated/test/Commands.h @@ -42570,7 +42570,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_1(error); } - static void OnSuccessCallback_1(void * context, int16_t maxPressure) + static void OnSuccessCallback_1(void * context, const chip::app::DataModel::Nullable & maxPressure) { (static_cast(context))->OnSuccessResponse_1(maxPressure); } @@ -42580,7 +42580,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_2(error); } - static void OnSuccessCallback_2(void * context, uint16_t maxSpeed) + static void OnSuccessCallback_2(void * context, const chip::app::DataModel::Nullable & maxSpeed) { (static_cast(context))->OnSuccessResponse_2(maxSpeed); } @@ -42590,7 +42590,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_3(error); } - static void OnSuccessCallback_3(void * context, uint16_t maxFlow) + static void OnSuccessCallback_3(void * context, const chip::app::DataModel::Nullable & maxFlow) { (static_cast(context))->OnSuccessResponse_3(maxFlow); } @@ -42600,7 +42600,8 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_4(error); } - static void OnSuccessCallback_4(void * context, uint8_t effectiveOperationMode) + static void OnSuccessCallback_4(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode effectiveOperationMode) { (static_cast(context))->OnSuccessResponse_4(effectiveOperationMode); } @@ -42610,7 +42611,8 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_5(error); } - static void OnSuccessCallback_5(void * context, uint8_t effectiveControlMode) + static void OnSuccessCallback_5(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { (static_cast(context))->OnSuccessResponse_5(effectiveControlMode); } @@ -42620,7 +42622,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_6(error); } - static void OnSuccessCallback_6(void * context, int16_t capacity) + static void OnSuccessCallback_6(void * context, const chip::app::DataModel::Nullable & capacity) { (static_cast(context))->OnSuccessResponse_6(capacity); } @@ -42630,7 +42632,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_7(error); } - static void OnSuccessCallback_7(void * context, int16_t maxPressure) + static void OnSuccessCallback_7(void * context, const chip::app::DataModel::Nullable & maxPressure) { (static_cast(context))->OnSuccessResponse_7(maxPressure); } @@ -42640,7 +42642,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_8(error); } - static void OnSuccessCallback_8(void * context, uint16_t maxSpeed) + static void OnSuccessCallback_8(void * context, const chip::app::DataModel::Nullable & maxSpeed) { (static_cast(context))->OnSuccessResponse_8(maxSpeed); } @@ -42650,7 +42652,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_9(error); } - static void OnSuccessCallback_9(void * context, uint16_t maxFlow) + static void OnSuccessCallback_9(void * context, const chip::app::DataModel::Nullable & maxFlow) { (static_cast(context))->OnSuccessResponse_9(maxFlow); } @@ -42660,7 +42662,8 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_10(error); } - static void OnSuccessCallback_10(void * context, uint8_t effectiveOperationMode) + static void OnSuccessCallback_10(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode effectiveOperationMode) { (static_cast(context))->OnSuccessResponse_10(effectiveOperationMode); } @@ -42670,7 +42673,8 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_11(error); } - static void OnSuccessCallback_11(void * context, uint8_t effectiveControlMode) + static void OnSuccessCallback_11(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { (static_cast(context))->OnSuccessResponse_11(effectiveControlMode); } @@ -42680,7 +42684,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_12(error); } - static void OnSuccessCallback_12(void * context, int16_t capacity) + static void OnSuccessCallback_12(void * context, const chip::app::DataModel::Nullable & capacity) { (static_cast(context))->OnSuccessResponse_12(capacity); } @@ -42690,7 +42694,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_13(error); } - static void OnSuccessCallback_13(void * context, int16_t minConstPressure) + static void OnSuccessCallback_13(void * context, const chip::app::DataModel::Nullable & minConstPressure) { (static_cast(context))->OnSuccessResponse_13(minConstPressure); } @@ -42700,7 +42704,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_14(error); } - static void OnSuccessCallback_14(void * context, int16_t maxConstPressure) + static void OnSuccessCallback_14(void * context, const chip::app::DataModel::Nullable & maxConstPressure) { (static_cast(context))->OnSuccessResponse_14(maxConstPressure); } @@ -42710,7 +42714,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_15(error); } - static void OnSuccessCallback_15(void * context, int16_t minCompPressure) + static void OnSuccessCallback_15(void * context, const chip::app::DataModel::Nullable & minCompPressure) { (static_cast(context))->OnSuccessResponse_15(minCompPressure); } @@ -42720,7 +42724,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_16(error); } - static void OnSuccessCallback_16(void * context, int16_t maxCompPressure) + static void OnSuccessCallback_16(void * context, const chip::app::DataModel::Nullable & maxCompPressure) { (static_cast(context))->OnSuccessResponse_16(maxCompPressure); } @@ -42730,7 +42734,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_17(error); } - static void OnSuccessCallback_17(void * context, uint16_t minConstSpeed) + static void OnSuccessCallback_17(void * context, const chip::app::DataModel::Nullable & minConstSpeed) { (static_cast(context))->OnSuccessResponse_17(minConstSpeed); } @@ -42740,7 +42744,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_18(error); } - static void OnSuccessCallback_18(void * context, uint16_t maxConstSpeed) + static void OnSuccessCallback_18(void * context, const chip::app::DataModel::Nullable & maxConstSpeed) { (static_cast(context))->OnSuccessResponse_18(maxConstSpeed); } @@ -42750,7 +42754,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_19(error); } - static void OnSuccessCallback_19(void * context, uint16_t minConstFlow) + static void OnSuccessCallback_19(void * context, const chip::app::DataModel::Nullable & minConstFlow) { (static_cast(context))->OnSuccessResponse_19(minConstFlow); } @@ -42760,7 +42764,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_20(error); } - static void OnSuccessCallback_20(void * context, uint16_t maxConstFlow) + static void OnSuccessCallback_20(void * context, const chip::app::DataModel::Nullable & maxConstFlow) { (static_cast(context))->OnSuccessResponse_20(maxConstFlow); } @@ -42770,7 +42774,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_21(error); } - static void OnSuccessCallback_21(void * context, int16_t minConstTemp) + static void OnSuccessCallback_21(void * context, const chip::app::DataModel::Nullable & minConstTemp) { (static_cast(context))->OnSuccessResponse_21(minConstTemp); } @@ -42780,7 +42784,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_22(error); } - static void OnSuccessCallback_22(void * context, int16_t maxConstTemp) + static void OnSuccessCallback_22(void * context, const chip::app::DataModel::Nullable & maxConstTemp) { (static_cast(context))->OnSuccessResponse_22(maxConstTemp); } @@ -42810,7 +42814,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_25(error); } - static void OnSuccessCallback_25(void * context, uint16_t speed) + static void OnSuccessCallback_25(void * context, const chip::app::DataModel::Nullable & speed) { (static_cast(context))->OnSuccessResponse_25(speed); } @@ -42840,7 +42844,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_28(error); } - static void OnSuccessCallback_28(void * context, uint32_t power) + static void OnSuccessCallback_28(void * context, const chip::app::DataModel::Nullable & power) { (static_cast(context))->OnSuccessResponse_28(power); } @@ -42877,7 +42881,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_32(error); } - static void OnSuccessCallback_32(void * context, int16_t minConstPressure) + static void OnSuccessCallback_32(void * context, const chip::app::DataModel::Nullable & minConstPressure) { (static_cast(context))->OnSuccessResponse_32(minConstPressure); } @@ -42887,7 +42891,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_33(error); } - static void OnSuccessCallback_33(void * context, int16_t maxConstPressure) + static void OnSuccessCallback_33(void * context, const chip::app::DataModel::Nullable & maxConstPressure) { (static_cast(context))->OnSuccessResponse_33(maxConstPressure); } @@ -42897,7 +42901,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_34(error); } - static void OnSuccessCallback_34(void * context, int16_t minCompPressure) + static void OnSuccessCallback_34(void * context, const chip::app::DataModel::Nullable & minCompPressure) { (static_cast(context))->OnSuccessResponse_34(minCompPressure); } @@ -42907,7 +42911,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_35(error); } - static void OnSuccessCallback_35(void * context, int16_t maxCompPressure) + static void OnSuccessCallback_35(void * context, const chip::app::DataModel::Nullable & maxCompPressure) { (static_cast(context))->OnSuccessResponse_35(maxCompPressure); } @@ -42917,7 +42921,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_36(error); } - static void OnSuccessCallback_36(void * context, uint16_t minConstSpeed) + static void OnSuccessCallback_36(void * context, const chip::app::DataModel::Nullable & minConstSpeed) { (static_cast(context))->OnSuccessResponse_36(minConstSpeed); } @@ -42927,7 +42931,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_37(error); } - static void OnSuccessCallback_37(void * context, uint16_t maxConstSpeed) + static void OnSuccessCallback_37(void * context, const chip::app::DataModel::Nullable & maxConstSpeed) { (static_cast(context))->OnSuccessResponse_37(maxConstSpeed); } @@ -42937,7 +42941,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_38(error); } - static void OnSuccessCallback_38(void * context, uint16_t minConstFlow) + static void OnSuccessCallback_38(void * context, const chip::app::DataModel::Nullable & minConstFlow) { (static_cast(context))->OnSuccessResponse_38(minConstFlow); } @@ -42947,7 +42951,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_39(error); } - static void OnSuccessCallback_39(void * context, uint16_t maxConstFlow) + static void OnSuccessCallback_39(void * context, const chip::app::DataModel::Nullable & maxConstFlow) { (static_cast(context))->OnSuccessResponse_39(maxConstFlow); } @@ -42957,7 +42961,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_40(error); } - static void OnSuccessCallback_40(void * context, int16_t minConstTemp) + static void OnSuccessCallback_40(void * context, const chip::app::DataModel::Nullable & minConstTemp) { (static_cast(context))->OnSuccessResponse_40(minConstTemp); } @@ -42967,7 +42971,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_41(error); } - static void OnSuccessCallback_41(void * context, int16_t maxConstTemp) + static void OnSuccessCallback_41(void * context, const chip::app::DataModel::Nullable & maxConstTemp) { (static_cast(context))->OnSuccessResponse_41(maxConstTemp); } @@ -42997,7 +43001,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_44(error); } - static void OnSuccessCallback_44(void * context, uint16_t speed) + static void OnSuccessCallback_44(void * context, const chip::app::DataModel::Nullable & speed) { (static_cast(context))->OnSuccessResponse_44(speed); } @@ -43027,7 +43031,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand (static_cast(context))->OnFailureResponse_47(error); } - static void OnSuccessCallback_47(void * context, uint32_t power) + static void OnSuccessCallback_47(void * context, const chip::app::DataModel::Nullable & power) { (static_cast(context))->OnSuccessResponse_47(power); } @@ -43080,7 +43084,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_1(int16_t maxPressure) + void OnSuccessResponse_1(const chip::app::DataModel::Nullable & maxPressure) { VerifyOrReturn(CheckConstraintType("maxPressure", "", "int16")); NextTest(); @@ -43104,7 +43108,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_2(uint16_t maxSpeed) + void OnSuccessResponse_2(const chip::app::DataModel::Nullable & maxSpeed) { VerifyOrReturn(CheckConstraintType("maxSpeed", "", "uint16")); NextTest(); @@ -43127,7 +43131,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_3(uint16_t maxFlow) + void OnSuccessResponse_3(const chip::app::DataModel::Nullable & maxFlow) { VerifyOrReturn(CheckConstraintType("maxFlow", "", "uint16")); NextTest(); @@ -43151,7 +43155,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_4(uint8_t effectiveOperationMode) + void OnSuccessResponse_4(chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode effectiveOperationMode) { VerifyOrReturn(CheckConstraintType("effectiveOperationMode", "", "enum8")); NextTest(); @@ -43175,7 +43179,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_5(uint8_t effectiveControlMode) + void OnSuccessResponse_5(chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { VerifyOrReturn(CheckConstraintType("effectiveControlMode", "", "enum8")); NextTest(); @@ -43199,7 +43203,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_6(int16_t capacity) + void OnSuccessResponse_6(const chip::app::DataModel::Nullable & capacity) { VerifyOrReturn(CheckConstraintType("capacity", "", "int16")); NextTest(); @@ -43223,7 +43227,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_7(int16_t maxPressure) + void OnSuccessResponse_7(const chip::app::DataModel::Nullable & maxPressure) { VerifyOrReturn(CheckConstraintType("maxPressure", "", "int16")); NextTest(); @@ -43247,7 +43251,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_8(uint16_t maxSpeed) + void OnSuccessResponse_8(const chip::app::DataModel::Nullable & maxSpeed) { VerifyOrReturn(CheckConstraintType("maxSpeed", "", "uint16")); NextTest(); @@ -43270,7 +43274,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_9(uint16_t maxFlow) + void OnSuccessResponse_9(const chip::app::DataModel::Nullable & maxFlow) { VerifyOrReturn(CheckConstraintType("maxFlow", "", "uint16")); NextTest(); @@ -43294,7 +43298,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_10(uint8_t effectiveOperationMode) + void OnSuccessResponse_10(chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode effectiveOperationMode) { VerifyOrReturn(CheckConstraintType("effectiveOperationMode", "", "enum8")); NextTest(); @@ -43318,7 +43322,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_11(uint8_t effectiveControlMode) + void OnSuccessResponse_11(chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { VerifyOrReturn(CheckConstraintType("effectiveControlMode", "", "enum8")); NextTest(); @@ -43342,7 +43346,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_12(int16_t capacity) + void OnSuccessResponse_12(const chip::app::DataModel::Nullable & capacity) { VerifyOrReturn(CheckConstraintType("capacity", "", "int16")); NextTest(); @@ -43367,7 +43371,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_13(int16_t minConstPressure) + void OnSuccessResponse_13(const chip::app::DataModel::Nullable & minConstPressure) { VerifyOrReturn(CheckConstraintType("minConstPressure", "", "int16")); NextTest(); @@ -43392,7 +43396,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_14(int16_t maxConstPressure) + void OnSuccessResponse_14(const chip::app::DataModel::Nullable & maxConstPressure) { VerifyOrReturn(CheckConstraintType("maxConstPressure", "", "int16")); NextTest(); @@ -43417,7 +43421,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_15(int16_t minCompPressure) + void OnSuccessResponse_15(const chip::app::DataModel::Nullable & minCompPressure) { VerifyOrReturn(CheckConstraintType("minCompPressure", "", "int16")); NextTest(); @@ -43442,7 +43446,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_16(int16_t maxCompPressure) + void OnSuccessResponse_16(const chip::app::DataModel::Nullable & maxCompPressure) { VerifyOrReturn(CheckConstraintType("maxCompPressure", "", "int16")); NextTest(); @@ -43467,7 +43471,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_17(uint16_t minConstSpeed) + void OnSuccessResponse_17(const chip::app::DataModel::Nullable & minConstSpeed) { VerifyOrReturn(CheckConstraintType("minConstSpeed", "", "uint16")); NextTest(); @@ -43492,7 +43496,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_18(uint16_t maxConstSpeed) + void OnSuccessResponse_18(const chip::app::DataModel::Nullable & maxConstSpeed) { VerifyOrReturn(CheckConstraintType("maxConstSpeed", "", "uint16")); NextTest(); @@ -43517,7 +43521,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_19(uint16_t minConstFlow) + void OnSuccessResponse_19(const chip::app::DataModel::Nullable & minConstFlow) { VerifyOrReturn(CheckConstraintType("minConstFlow", "", "uint16")); NextTest(); @@ -43542,7 +43546,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_20(uint16_t maxConstFlow) + void OnSuccessResponse_20(const chip::app::DataModel::Nullable & maxConstFlow) { VerifyOrReturn(CheckConstraintType("maxConstFlow", "", "uint16")); NextTest(); @@ -43567,7 +43571,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_21(int16_t minConstTemp) + void OnSuccessResponse_21(const chip::app::DataModel::Nullable & minConstTemp) { VerifyOrReturn(CheckConstraintType("minConstTemp", "", "int16")); VerifyOrReturn(CheckConstraintMinValue("minConstTemp", minConstTemp, -27315)); @@ -43593,7 +43597,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_22(int16_t maxConstTemp) + void OnSuccessResponse_22(const chip::app::DataModel::Nullable & maxConstTemp) { VerifyOrReturn(CheckConstraintType("maxConstTemp", "", "int16")); VerifyOrReturn(CheckConstraintMinValue("maxConstTemp", maxConstTemp, -27315)); @@ -43669,7 +43673,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_25(uint16_t speed) + void OnSuccessResponse_25(const chip::app::DataModel::Nullable & speed) { VerifyOrReturn(CheckConstraintType("speed", "", "uint16")); NextTest(); @@ -43745,7 +43749,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_28(uint32_t power) + void OnSuccessResponse_28(const chip::app::DataModel::Nullable & power) { VerifyOrReturn(CheckConstraintType("power", "", "uint24")); NextTest(); @@ -43847,7 +43851,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_32(int16_t minConstPressure) + void OnSuccessResponse_32(const chip::app::DataModel::Nullable & minConstPressure) { VerifyOrReturn(CheckConstraintType("minConstPressure", "", "int16")); NextTest(); @@ -43872,7 +43876,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_33(int16_t maxConstPressure) + void OnSuccessResponse_33(const chip::app::DataModel::Nullable & maxConstPressure) { VerifyOrReturn(CheckConstraintType("maxConstPressure", "", "int16")); NextTest(); @@ -43897,7 +43901,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_34(int16_t minCompPressure) + void OnSuccessResponse_34(const chip::app::DataModel::Nullable & minCompPressure) { VerifyOrReturn(CheckConstraintType("minCompPressure", "", "int16")); NextTest(); @@ -43922,7 +43926,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_35(int16_t maxCompPressure) + void OnSuccessResponse_35(const chip::app::DataModel::Nullable & maxCompPressure) { VerifyOrReturn(CheckConstraintType("maxCompPressure", "", "int16")); NextTest(); @@ -43947,7 +43951,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_36(uint16_t minConstSpeed) + void OnSuccessResponse_36(const chip::app::DataModel::Nullable & minConstSpeed) { VerifyOrReturn(CheckConstraintType("minConstSpeed", "", "uint16")); NextTest(); @@ -43972,7 +43976,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_37(uint16_t maxConstSpeed) + void OnSuccessResponse_37(const chip::app::DataModel::Nullable & maxConstSpeed) { VerifyOrReturn(CheckConstraintType("maxConstSpeed", "", "uint16")); NextTest(); @@ -43997,7 +44001,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_38(uint16_t minConstFlow) + void OnSuccessResponse_38(const chip::app::DataModel::Nullable & minConstFlow) { VerifyOrReturn(CheckConstraintType("minConstFlow", "", "uint16")); NextTest(); @@ -44022,7 +44026,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_39(uint16_t maxConstFlow) + void OnSuccessResponse_39(const chip::app::DataModel::Nullable & maxConstFlow) { VerifyOrReturn(CheckConstraintType("maxConstFlow", "", "uint16")); NextTest(); @@ -44047,7 +44051,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_40(int16_t minConstTemp) + void OnSuccessResponse_40(const chip::app::DataModel::Nullable & minConstTemp) { VerifyOrReturn(CheckConstraintType("minConstTemp", "", "int16")); VerifyOrReturn(CheckConstraintMinValue("minConstTemp", minConstTemp, -27315)); @@ -44074,7 +44078,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_41(int16_t maxConstTemp) + void OnSuccessResponse_41(const chip::app::DataModel::Nullable & maxConstTemp) { VerifyOrReturn(CheckConstraintType("maxConstTemp", "", "int16")); VerifyOrReturn(CheckConstraintMinValue("maxConstTemp", maxConstTemp, -27315)); @@ -44151,7 +44155,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_44(uint16_t speed) + void OnSuccessResponse_44(const chip::app::DataModel::Nullable & speed) { VerifyOrReturn(CheckConstraintType("speed", "", "uint16")); NextTest(); @@ -44226,7 +44230,7 @@ class Test_TC_PCC_2_1Suite : public TestCommand : ThrowFailureResponse(error); } - void OnSuccessResponse_47(uint32_t power) + void OnSuccessResponse_47(const chip::app::DataModel::Nullable & power) { VerifyOrReturn(CheckConstraintType("power", "", "uint24")); NextTest(); @@ -44437,7 +44441,8 @@ class Test_TC_PCC_2_2Suite : public TestCommand (static_cast(context))->OnFailureResponse_2(error); } - static void OnSuccessCallback_2(void * context, uint8_t effectiveOperationMode) + static void OnSuccessCallback_2(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode effectiveOperationMode) { (static_cast(context))->OnSuccessResponse_2(effectiveOperationMode); } @@ -44454,7 +44459,8 @@ class Test_TC_PCC_2_2Suite : public TestCommand (static_cast(context))->OnFailureResponse_4(error); } - static void OnSuccessCallback_4(void * context, uint8_t effectiveOperationMode) + static void OnSuccessCallback_4(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode effectiveOperationMode) { (static_cast(context))->OnSuccessResponse_4(effectiveOperationMode); } @@ -44471,7 +44477,8 @@ class Test_TC_PCC_2_2Suite : public TestCommand (static_cast(context))->OnFailureResponse_6(error); } - static void OnSuccessCallback_6(void * context, uint8_t effectiveOperationMode) + static void OnSuccessCallback_6(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode effectiveOperationMode) { (static_cast(context))->OnSuccessResponse_6(effectiveOperationMode); } @@ -44492,8 +44499,8 @@ class Test_TC_PCC_2_2Suite : public TestCommand chip::Controller::PumpConfigurationAndControlClusterTest cluster; cluster.Associate(mDevices[kIdentityAlpha], endpoint); - uint8_t operationModeArgument; - operationModeArgument = 1; + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode operationModeArgument; + operationModeArgument = static_cast(1); ReturnErrorOnFailure( cluster.WriteAttribute( @@ -44527,7 +44534,7 @@ class Test_TC_PCC_2_2Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_2(uint8_t effectiveOperationMode) + void OnSuccessResponse_2(chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode effectiveOperationMode) { VerifyOrReturn(CheckValue("effectiveOperationMode", effectiveOperationMode, 1)); @@ -44540,8 +44547,8 @@ class Test_TC_PCC_2_2Suite : public TestCommand chip::Controller::PumpConfigurationAndControlClusterTest cluster; cluster.Associate(mDevices[kIdentityAlpha], endpoint); - uint8_t operationModeArgument; - operationModeArgument = 2; + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode operationModeArgument; + operationModeArgument = static_cast(2); ReturnErrorOnFailure( cluster.WriteAttribute( @@ -44575,7 +44582,7 @@ class Test_TC_PCC_2_2Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_4(uint8_t effectiveOperationMode) + void OnSuccessResponse_4(chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode effectiveOperationMode) { VerifyOrReturn(CheckValue("effectiveOperationMode", effectiveOperationMode, 2)); @@ -44588,8 +44595,8 @@ class Test_TC_PCC_2_2Suite : public TestCommand chip::Controller::PumpConfigurationAndControlClusterTest cluster; cluster.Associate(mDevices[kIdentityAlpha], endpoint); - uint8_t operationModeArgument; - operationModeArgument = 3; + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode operationModeArgument; + operationModeArgument = static_cast(3); ReturnErrorOnFailure( cluster.WriteAttribute( @@ -44623,7 +44630,7 @@ class Test_TC_PCC_2_2Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_6(uint8_t effectiveOperationMode) + void OnSuccessResponse_6(chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode effectiveOperationMode) { VerifyOrReturn(CheckValue("effectiveOperationMode", effectiveOperationMode, 3)); @@ -44855,7 +44862,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand (static_cast(context))->OnFailureResponse_2(error); } - static void OnSuccessCallback_2(void * context, uint8_t effectiveOperationMode) + static void OnSuccessCallback_2(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode effectiveOperationMode) { (static_cast(context))->OnSuccessResponse_2(effectiveOperationMode); } @@ -44872,7 +44880,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand (static_cast(context))->OnFailureResponse_4(error); } - static void OnSuccessCallback_4(void * context, uint8_t effectiveControlMode) + static void OnSuccessCallback_4(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { (static_cast(context))->OnSuccessResponse_4(effectiveControlMode); } @@ -44889,7 +44898,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand (static_cast(context))->OnFailureResponse_6(error); } - static void OnSuccessCallback_6(void * context, uint8_t effectiveControlMode) + static void OnSuccessCallback_6(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { (static_cast(context))->OnSuccessResponse_6(effectiveControlMode); } @@ -44906,7 +44916,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand (static_cast(context))->OnFailureResponse_8(error); } - static void OnSuccessCallback_8(void * context, uint8_t effectiveControlMode) + static void OnSuccessCallback_8(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { (static_cast(context))->OnSuccessResponse_8(effectiveControlMode); } @@ -44923,7 +44934,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand (static_cast(context))->OnFailureResponse_10(error); } - static void OnSuccessCallback_10(void * context, uint8_t effectiveControlMode) + static void OnSuccessCallback_10(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { (static_cast(context))->OnSuccessResponse_10(effectiveControlMode); } @@ -44940,7 +44952,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand (static_cast(context))->OnFailureResponse_12(error); } - static void OnSuccessCallback_12(void * context, uint8_t effectiveControlMode) + static void OnSuccessCallback_12(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { (static_cast(context))->OnSuccessResponse_12(effectiveControlMode); } @@ -44957,7 +44970,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand (static_cast(context))->OnFailureResponse_14(error); } - static void OnSuccessCallback_14(void * context, uint8_t effectiveControlMode) + static void OnSuccessCallback_14(void * context, + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { (static_cast(context))->OnSuccessResponse_14(effectiveControlMode); } @@ -44978,8 +44992,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand chip::Controller::PumpConfigurationAndControlClusterTest cluster; cluster.Associate(mDevices[kIdentityAlpha], endpoint); - uint8_t operationModeArgument; - operationModeArgument = 0; + chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode operationModeArgument; + operationModeArgument = static_cast(0); ReturnErrorOnFailure( cluster.WriteAttribute( @@ -45013,7 +45027,7 @@ class Test_TC_PCC_2_3Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_2(uint8_t effectiveOperationMode) + void OnSuccessResponse_2(chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode effectiveOperationMode) { VerifyOrReturn(CheckValue("effectiveOperationMode", effectiveOperationMode, 0)); @@ -45026,8 +45040,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand chip::Controller::PumpConfigurationAndControlClusterTest cluster; cluster.Associate(mDevices[kIdentityAlpha], endpoint); - uint8_t controlModeArgument; - controlModeArgument = 0; + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode controlModeArgument; + controlModeArgument = static_cast(0); ReturnErrorOnFailure( cluster.WriteAttribute( @@ -45061,7 +45075,7 @@ class Test_TC_PCC_2_3Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_4(uint8_t effectiveControlMode) + void OnSuccessResponse_4(chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { VerifyOrReturn(CheckValue("effectiveControlMode", effectiveControlMode, 0)); @@ -45074,8 +45088,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand chip::Controller::PumpConfigurationAndControlClusterTest cluster; cluster.Associate(mDevices[kIdentityAlpha], endpoint); - uint8_t controlModeArgument; - controlModeArgument = 1; + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode controlModeArgument; + controlModeArgument = static_cast(1); ReturnErrorOnFailure( cluster.WriteAttribute( @@ -45109,7 +45123,7 @@ class Test_TC_PCC_2_3Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_6(uint8_t effectiveControlMode) + void OnSuccessResponse_6(chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { VerifyOrReturn(CheckValue("effectiveControlMode", effectiveControlMode, 1)); @@ -45122,8 +45136,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand chip::Controller::PumpConfigurationAndControlClusterTest cluster; cluster.Associate(mDevices[kIdentityAlpha], endpoint); - uint8_t controlModeArgument; - controlModeArgument = 2; + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode controlModeArgument; + controlModeArgument = static_cast(2); ReturnErrorOnFailure( cluster.WriteAttribute( @@ -45157,7 +45171,7 @@ class Test_TC_PCC_2_3Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_8(uint8_t effectiveControlMode) + void OnSuccessResponse_8(chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { VerifyOrReturn(CheckValue("effectiveControlMode", effectiveControlMode, 2)); @@ -45170,8 +45184,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand chip::Controller::PumpConfigurationAndControlClusterTest cluster; cluster.Associate(mDevices[kIdentityAlpha], endpoint); - uint8_t controlModeArgument; - controlModeArgument = 3; + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode controlModeArgument; + controlModeArgument = static_cast(3); ReturnErrorOnFailure( cluster.WriteAttribute( @@ -45205,7 +45219,7 @@ class Test_TC_PCC_2_3Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_10(uint8_t effectiveControlMode) + void OnSuccessResponse_10(chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { VerifyOrReturn(CheckValue("effectiveControlMode", effectiveControlMode, 3)); @@ -45218,8 +45232,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand chip::Controller::PumpConfigurationAndControlClusterTest cluster; cluster.Associate(mDevices[kIdentityAlpha], endpoint); - uint8_t controlModeArgument; - controlModeArgument = 5; + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode controlModeArgument; + controlModeArgument = static_cast(5); ReturnErrorOnFailure( cluster.WriteAttribute( @@ -45253,7 +45267,7 @@ class Test_TC_PCC_2_3Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_12(uint8_t effectiveControlMode) + void OnSuccessResponse_12(chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { VerifyOrReturn(CheckValue("effectiveControlMode", effectiveControlMode, 5)); @@ -45266,8 +45280,8 @@ class Test_TC_PCC_2_3Suite : public TestCommand chip::Controller::PumpConfigurationAndControlClusterTest cluster; cluster.Associate(mDevices[kIdentityAlpha], endpoint); - uint8_t controlModeArgument; - controlModeArgument = 7; + chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode controlModeArgument; + controlModeArgument = static_cast(7); ReturnErrorOnFailure( cluster.WriteAttribute( @@ -45301,7 +45315,7 @@ class Test_TC_PCC_2_3Suite : public TestCommand ThrowFailureResponse(error); } - void OnSuccessResponse_14(uint8_t effectiveControlMode) + void OnSuccessResponse_14(chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode effectiveControlMode) { VerifyOrReturn(CheckValue("effectiveControlMode", effectiveControlMode, 7)); diff --git a/zzz_generated/placeholder/app1/zap-generated/access.h b/zzz_generated/placeholder/app1/zap-generated/access.h index 7305fea621c8b2..4bbe080b592b7d 100644 --- a/zzz_generated/placeholder/app1/zap-generated/access.h +++ b/zzz_generated/placeholder/app1/zap-generated/access.h @@ -41,6 +41,10 @@ 49, /* Cluster: Network Commissioning, Attribute: LastNetworkID, Privilege: administer */ \ 49, /* Cluster: Network Commissioning, Attribute: LastConnectErrorValue, Privilege: administer */ \ /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: view */ \ @@ -67,6 +71,10 @@ 6, /* Cluster: Network Commissioning, Attribute: LastNetworkID, Privilege: administer */ \ 7, /* Cluster: Network Commissioning, Attribute: LastConnectErrorValue, Privilege: administer */ \ /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: view */ \ @@ -93,6 +101,10 @@ kMatterAccessPrivilegeAdminister, /* Cluster: Network Commissioning, Attribute: LastNetworkID, Privilege: administer */ \ kMatterAccessPrivilegeAdminister, /* Cluster: Network Commissioning, Attribute: LastConnectErrorValue, Privilege: administer */ \ /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: view */ \ @@ -116,6 +128,10 @@ 48, /* Cluster: General Commissioning, Attribute: Breadcrumb, Privilege: administer */ \ 49, /* Cluster: Network Commissioning, Attribute: InterfaceEnabled, Privilege: administer */ \ 6, /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: manage */ \ 513, /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: manage */ \ 513, /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: manage */ \ 513, /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: manage */ \ @@ -137,6 +153,10 @@ 0, /* Cluster: General Commissioning, Attribute: Breadcrumb, Privilege: administer */ \ 4, /* Cluster: Network Commissioning, Attribute: InterfaceEnabled, Privilege: administer */ \ 16387, /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: manage */ \ + 21, /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: manage */ \ + 23, /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: manage */ \ + 32, /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: manage */ \ + 33, /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: manage */ \ 21, /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: manage */ \ 22, /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: manage */ \ 23, /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: manage */ \ @@ -158,6 +178,10 @@ kMatterAccessPrivilegeAdminister, /* Cluster: General Commissioning, Attribute: Breadcrumb, Privilege: administer */ \ kMatterAccessPrivilegeAdminister, /* Cluster: Network Commissioning, Attribute: InterfaceEnabled, Privilege: administer */ \ kMatterAccessPrivilegeManage, /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: manage */ \ kMatterAccessPrivilegeManage, /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: manage */ \ kMatterAccessPrivilegeManage, /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: manage */ \ kMatterAccessPrivilegeManage, /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: manage */ \ diff --git a/zzz_generated/placeholder/app1/zap-generated/endpoint_config.h b/zzz_generated/placeholder/app1/zap-generated/endpoint_config.h index e347a7179e1cce..81bd23ceb3da39 100644 --- a/zzz_generated/placeholder/app1/zap-generated/endpoint_config.h +++ b/zzz_generated/placeholder/app1/zap-generated/endpoint_config.h @@ -433,8 +433,8 @@ { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0xF }, /* Mode */ \ \ /* Endpoint: 0, Cluster: Pump Configuration and Control (server) */ \ - { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0xFE }, /* OperationMode */ \ - { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0xFE }, /* ControlMode */ \ + { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0x3 }, /* OperationMode */ \ + { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0x7 }, /* ControlMode */ \ \ /* Endpoint: 0, Cluster: Thermostat (server) */ \ { (uint16_t) 0x2BC, (uint16_t) 0x954D, (uint16_t) 0x7FFF }, /* min heat setpoint limit */ \ @@ -722,27 +722,27 @@ { 0x0000FFFD, ZAP_TYPE(INT16U), 2, 0, ZAP_SIMPLE_DEFAULT(5) }, /* ClusterRevision */ \ \ /* Endpoint: 0, Cluster: Pump Configuration and Control (server) */ \ - { 0x00000000, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxPressure */ \ - { 0x00000001, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxSpeed */ \ - { 0x00000002, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxFlow */ \ - { 0x00000003, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstPressure */ \ - { 0x00000004, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstPressure */ \ - { 0x00000005, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinCompPressure */ \ - { 0x00000006, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxCompPressure */ \ - { 0x00000007, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstSpeed */ \ - { 0x00000008, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstSpeed */ \ - { 0x00000009, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstFlow */ \ - { 0x0000000A, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstFlow */ \ - { 0x0000000B, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstTemp */ \ - { 0x0000000C, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstTemp */ \ - { 0x00000010, ZAP_TYPE(BITMAP16), 2, 0, ZAP_EMPTY_DEFAULT() }, /* PumpStatus */ \ - { 0x00000011, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveOperationMode */ \ - { 0x00000012, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveControlMode */ \ - { 0x00000013, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* Capacity */ \ - { 0x00000014, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* Speed */ \ + { 0x00000000, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxPressure */ \ + { 0x00000001, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxSpeed */ \ + { 0x00000002, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxFlow */ \ + { 0x00000003, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstPressure */ \ + { 0x00000004, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstPressure */ \ + { 0x00000005, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinCompPressure */ \ + { 0x00000006, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxCompPressure */ \ + { 0x00000007, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstSpeed */ \ + { 0x00000008, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstSpeed */ \ + { 0x00000009, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstFlow */ \ + { 0x0000000A, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstFlow */ \ + { 0x0000000B, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstTemp */ \ + { 0x0000000C, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstTemp */ \ + { 0x00000010, ZAP_TYPE(BITMAP16), 2, 0, ZAP_EMPTY_DEFAULT() }, /* PumpStatus */ \ + { 0x00000011, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveOperationMode */ \ + { 0x00000012, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveControlMode */ \ + { 0x00000013, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* Capacity */ \ + { 0x00000014, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* Speed */ \ { 0x00000015, ZAP_TYPE(INT24U), 3, ZAP_ATTRIBUTE_MASK(WRITABLE) | ZAP_ATTRIBUTE_MASK(NULLABLE), \ - ZAP_LONG_DEFAULTS_INDEX(220) }, /* LifetimeRunningHours */ \ - { 0x00000016, ZAP_TYPE(INT24U), 3, 0, ZAP_LONG_DEFAULTS_INDEX(223) }, /* Power */ \ + ZAP_LONG_DEFAULTS_INDEX(220) }, /* LifetimeRunningHours */ \ + { 0x00000016, ZAP_TYPE(INT24U), 3, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_LONG_DEFAULTS_INDEX(223) }, /* Power */ \ { 0x00000017, ZAP_TYPE(INT32U), 4, ZAP_ATTRIBUTE_MASK(WRITABLE) | ZAP_ATTRIBUTE_MASK(NULLABLE), \ ZAP_LONG_DEFAULTS_INDEX(226) }, /* LifetimeEnergyConsumed */ \ { 0x00000020, ZAP_TYPE(ENUM8), 1, ZAP_ATTRIBUTE_MASK(MIN_MAX) | ZAP_ATTRIBUTE_MASK(WRITABLE), \ diff --git a/zzz_generated/placeholder/app2/zap-generated/access.h b/zzz_generated/placeholder/app2/zap-generated/access.h index 7305fea621c8b2..4bbe080b592b7d 100644 --- a/zzz_generated/placeholder/app2/zap-generated/access.h +++ b/zzz_generated/placeholder/app2/zap-generated/access.h @@ -41,6 +41,10 @@ 49, /* Cluster: Network Commissioning, Attribute: LastNetworkID, Privilege: administer */ \ 49, /* Cluster: Network Commissioning, Attribute: LastConnectErrorValue, Privilege: administer */ \ /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: view */ \ @@ -67,6 +71,10 @@ 6, /* Cluster: Network Commissioning, Attribute: LastNetworkID, Privilege: administer */ \ 7, /* Cluster: Network Commissioning, Attribute: LastConnectErrorValue, Privilege: administer */ \ /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: view */ \ @@ -93,6 +101,10 @@ kMatterAccessPrivilegeAdminister, /* Cluster: Network Commissioning, Attribute: LastNetworkID, Privilege: administer */ \ kMatterAccessPrivilegeAdminister, /* Cluster: Network Commissioning, Attribute: LastConnectErrorValue, Privilege: administer */ \ /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: view */ \ /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: view */ \ @@ -116,6 +128,10 @@ 48, /* Cluster: General Commissioning, Attribute: Breadcrumb, Privilege: administer */ \ 49, /* Cluster: Network Commissioning, Attribute: InterfaceEnabled, Privilege: administer */ \ 6, /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: manage */ \ 513, /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: manage */ \ 513, /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: manage */ \ 513, /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: manage */ \ @@ -137,6 +153,10 @@ 0, /* Cluster: General Commissioning, Attribute: Breadcrumb, Privilege: administer */ \ 4, /* Cluster: Network Commissioning, Attribute: InterfaceEnabled, Privilege: administer */ \ 16387, /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: manage */ \ + 21, /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: manage */ \ + 23, /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: manage */ \ + 32, /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: manage */ \ + 33, /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: manage */ \ 21, /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: manage */ \ 22, /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: manage */ \ 23, /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: manage */ \ @@ -158,6 +178,10 @@ kMatterAccessPrivilegeAdminister, /* Cluster: General Commissioning, Attribute: Breadcrumb, Privilege: administer */ \ kMatterAccessPrivilegeAdminister, /* Cluster: Network Commissioning, Attribute: InterfaceEnabled, Privilege: administer */ \ kMatterAccessPrivilegeManage, /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: manage */ \ kMatterAccessPrivilegeManage, /* Cluster: Thermostat, Attribute: min heat setpoint limit, Privilege: manage */ \ kMatterAccessPrivilegeManage, /* Cluster: Thermostat, Attribute: max heat setpoint limit, Privilege: manage */ \ kMatterAccessPrivilegeManage, /* Cluster: Thermostat, Attribute: min cool setpoint limit, Privilege: manage */ \ diff --git a/zzz_generated/placeholder/app2/zap-generated/endpoint_config.h b/zzz_generated/placeholder/app2/zap-generated/endpoint_config.h index e347a7179e1cce..81bd23ceb3da39 100644 --- a/zzz_generated/placeholder/app2/zap-generated/endpoint_config.h +++ b/zzz_generated/placeholder/app2/zap-generated/endpoint_config.h @@ -433,8 +433,8 @@ { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0xF }, /* Mode */ \ \ /* Endpoint: 0, Cluster: Pump Configuration and Control (server) */ \ - { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0xFE }, /* OperationMode */ \ - { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0xFE }, /* ControlMode */ \ + { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0x3 }, /* OperationMode */ \ + { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0x7 }, /* ControlMode */ \ \ /* Endpoint: 0, Cluster: Thermostat (server) */ \ { (uint16_t) 0x2BC, (uint16_t) 0x954D, (uint16_t) 0x7FFF }, /* min heat setpoint limit */ \ @@ -722,27 +722,27 @@ { 0x0000FFFD, ZAP_TYPE(INT16U), 2, 0, ZAP_SIMPLE_DEFAULT(5) }, /* ClusterRevision */ \ \ /* Endpoint: 0, Cluster: Pump Configuration and Control (server) */ \ - { 0x00000000, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxPressure */ \ - { 0x00000001, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxSpeed */ \ - { 0x00000002, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxFlow */ \ - { 0x00000003, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstPressure */ \ - { 0x00000004, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstPressure */ \ - { 0x00000005, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinCompPressure */ \ - { 0x00000006, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxCompPressure */ \ - { 0x00000007, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstSpeed */ \ - { 0x00000008, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstSpeed */ \ - { 0x00000009, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstFlow */ \ - { 0x0000000A, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstFlow */ \ - { 0x0000000B, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstTemp */ \ - { 0x0000000C, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstTemp */ \ - { 0x00000010, ZAP_TYPE(BITMAP16), 2, 0, ZAP_EMPTY_DEFAULT() }, /* PumpStatus */ \ - { 0x00000011, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveOperationMode */ \ - { 0x00000012, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveControlMode */ \ - { 0x00000013, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* Capacity */ \ - { 0x00000014, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* Speed */ \ + { 0x00000000, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxPressure */ \ + { 0x00000001, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxSpeed */ \ + { 0x00000002, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxFlow */ \ + { 0x00000003, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstPressure */ \ + { 0x00000004, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstPressure */ \ + { 0x00000005, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinCompPressure */ \ + { 0x00000006, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxCompPressure */ \ + { 0x00000007, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstSpeed */ \ + { 0x00000008, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstSpeed */ \ + { 0x00000009, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstFlow */ \ + { 0x0000000A, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstFlow */ \ + { 0x0000000B, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstTemp */ \ + { 0x0000000C, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstTemp */ \ + { 0x00000010, ZAP_TYPE(BITMAP16), 2, 0, ZAP_EMPTY_DEFAULT() }, /* PumpStatus */ \ + { 0x00000011, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveOperationMode */ \ + { 0x00000012, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveControlMode */ \ + { 0x00000013, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* Capacity */ \ + { 0x00000014, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* Speed */ \ { 0x00000015, ZAP_TYPE(INT24U), 3, ZAP_ATTRIBUTE_MASK(WRITABLE) | ZAP_ATTRIBUTE_MASK(NULLABLE), \ - ZAP_LONG_DEFAULTS_INDEX(220) }, /* LifetimeRunningHours */ \ - { 0x00000016, ZAP_TYPE(INT24U), 3, 0, ZAP_LONG_DEFAULTS_INDEX(223) }, /* Power */ \ + ZAP_LONG_DEFAULTS_INDEX(220) }, /* LifetimeRunningHours */ \ + { 0x00000016, ZAP_TYPE(INT24U), 3, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_LONG_DEFAULTS_INDEX(223) }, /* Power */ \ { 0x00000017, ZAP_TYPE(INT32U), 4, ZAP_ATTRIBUTE_MASK(WRITABLE) | ZAP_ATTRIBUTE_MASK(NULLABLE), \ ZAP_LONG_DEFAULTS_INDEX(226) }, /* LifetimeEnergyConsumed */ \ { 0x00000020, ZAP_TYPE(ENUM8), 1, ZAP_ATTRIBUTE_MASK(MIN_MAX) | ZAP_ATTRIBUTE_MASK(WRITABLE), \ diff --git a/zzz_generated/pump-app/zap-generated/access.h b/zzz_generated/pump-app/zap-generated/access.h index 9031d2b32619f6..d9d3086d106c71 100644 --- a/zzz_generated/pump-app/zap-generated/access.h +++ b/zzz_generated/pump-app/zap-generated/access.h @@ -48,6 +48,10 @@ 49, /* Cluster: Network Commissioning, Attribute: LastConnectErrorValue, Privilege: administer */ \ /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: view */ \ 62, /* Cluster: Operational Credentials, Attribute: NOCs, Privilege: administer */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: view */ \ /* Cluster: User Label, Attribute: label list, Privilege: view */ \ } @@ -72,6 +76,10 @@ 7, /* Cluster: Network Commissioning, Attribute: LastConnectErrorValue, Privilege: administer */ \ /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: view */ \ 0, /* Cluster: Operational Credentials, Attribute: NOCs, Privilege: administer */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: view */ \ /* Cluster: User Label, Attribute: label list, Privilege: view */ \ } @@ -96,6 +104,10 @@ kMatterAccessPrivilegeAdminister, /* Cluster: Network Commissioning, Attribute: LastConnectErrorValue, Privilege: administer */ \ /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: view */ \ kMatterAccessPrivilegeAdminister, /* Cluster: Operational Credentials, Attribute: NOCs, Privilege: administer */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: view */ \ + /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: view */ \ /* Cluster: User Label, Attribute: label list, Privilege: view */ \ } @@ -113,6 +125,10 @@ 8, /* Cluster: Level Control, Attribute: start up current level, Privilege: manage */ \ 49, /* Cluster: Network Commissioning, Attribute: InterfaceEnabled, Privilege: administer */ \ 6, /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: manage */ \ + 512, /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: manage */ \ 65, /* Cluster: User Label, Attribute: label list, Privilege: manage */ \ } @@ -128,6 +144,10 @@ 16384, /* Cluster: Level Control, Attribute: start up current level, Privilege: manage */ \ 4, /* Cluster: Network Commissioning, Attribute: InterfaceEnabled, Privilege: administer */ \ 16387, /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: manage */ \ + 21, /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: manage */ \ + 23, /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: manage */ \ + 32, /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: manage */ \ + 33, /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: manage */ \ 0, /* Cluster: User Label, Attribute: label list, Privilege: manage */ \ } @@ -143,6 +163,10 @@ kMatterAccessPrivilegeManage, /* Cluster: Level Control, Attribute: start up current level, Privilege: manage */ \ kMatterAccessPrivilegeAdminister, /* Cluster: Network Commissioning, Attribute: InterfaceEnabled, Privilege: administer */ \ kMatterAccessPrivilegeManage, /* Cluster: On/Off, Attribute: StartUpOnOff, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: LifetimeRunningHours, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: LifetimeEnergyConsumed, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: OperationMode, Privilege: manage */ \ + kMatterAccessPrivilegeManage, /* Cluster: Pump Configuration and Control, Attribute: ControlMode, Privilege: manage */ \ kMatterAccessPrivilegeManage, /* Cluster: User Label, Attribute: label list, Privilege: manage */ \ } diff --git a/zzz_generated/pump-app/zap-generated/endpoint_config.h b/zzz_generated/pump-app/zap-generated/endpoint_config.h index 9603f4fef95e15..d6b26a322f4985 100644 --- a/zzz_generated/pump-app/zap-generated/endpoint_config.h +++ b/zzz_generated/pump-app/zap-generated/endpoint_config.h @@ -670,9 +670,9 @@ { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0x3 }, /* options */ \ \ /* Endpoint: 1, Cluster: Pump Configuration and Control (server) */ \ - { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0xFE }, /* OperationMode */ \ + { (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0x3 }, /* OperationMode */ \ { \ - (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0xFE \ + (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0x7 \ } /* ControlMode */ \ } @@ -1003,27 +1003,27 @@ { 0x0000FFFD, ZAP_TYPE(INT16U), 0, ZAP_ATTRIBUTE_MASK(EXTERNAL_STORAGE), ZAP_EMPTY_DEFAULT() }, /* ClusterRevision */ \ \ /* Endpoint: 1, Cluster: Pump Configuration and Control (server) */ \ - { 0x00000000, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxPressure */ \ - { 0x00000001, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxSpeed */ \ - { 0x00000002, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxFlow */ \ - { 0x00000003, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstPressure */ \ - { 0x00000004, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstPressure */ \ - { 0x00000005, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinCompPressure */ \ - { 0x00000006, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxCompPressure */ \ - { 0x00000007, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstSpeed */ \ - { 0x00000008, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstSpeed */ \ - { 0x00000009, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstFlow */ \ - { 0x0000000A, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstFlow */ \ - { 0x0000000B, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MinConstTemp */ \ - { 0x0000000C, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* MaxConstTemp */ \ - { 0x00000010, ZAP_TYPE(BITMAP16), 2, 0, ZAP_EMPTY_DEFAULT() }, /* PumpStatus */ \ - { 0x00000011, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveOperationMode */ \ - { 0x00000012, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveControlMode */ \ - { 0x00000013, ZAP_TYPE(INT16S), 2, 0, ZAP_EMPTY_DEFAULT() }, /* Capacity */ \ - { 0x00000014, ZAP_TYPE(INT16U), 2, 0, ZAP_EMPTY_DEFAULT() }, /* Speed */ \ + { 0x00000000, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxPressure */ \ + { 0x00000001, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxSpeed */ \ + { 0x00000002, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxFlow */ \ + { 0x00000003, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstPressure */ \ + { 0x00000004, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstPressure */ \ + { 0x00000005, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinCompPressure */ \ + { 0x00000006, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxCompPressure */ \ + { 0x00000007, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstSpeed */ \ + { 0x00000008, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstSpeed */ \ + { 0x00000009, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstFlow */ \ + { 0x0000000A, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstFlow */ \ + { 0x0000000B, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MinConstTemp */ \ + { 0x0000000C, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* MaxConstTemp */ \ + { 0x00000010, ZAP_TYPE(BITMAP16), 2, 0, ZAP_EMPTY_DEFAULT() }, /* PumpStatus */ \ + { 0x00000011, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveOperationMode */ \ + { 0x00000012, ZAP_TYPE(ENUM8), 1, 0, ZAP_EMPTY_DEFAULT() }, /* EffectiveControlMode */ \ + { 0x00000013, ZAP_TYPE(INT16S), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* Capacity */ \ + { 0x00000014, ZAP_TYPE(INT16U), 2, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_EMPTY_DEFAULT() }, /* Speed */ \ { 0x00000015, ZAP_TYPE(INT24U), 3, ZAP_ATTRIBUTE_MASK(WRITABLE) | ZAP_ATTRIBUTE_MASK(NULLABLE), \ - ZAP_LONG_DEFAULTS_INDEX(335) }, /* LifetimeRunningHours */ \ - { 0x00000016, ZAP_TYPE(INT24U), 3, 0, ZAP_LONG_DEFAULTS_INDEX(338) }, /* Power */ \ + ZAP_LONG_DEFAULTS_INDEX(335) }, /* LifetimeRunningHours */ \ + { 0x00000016, ZAP_TYPE(INT24U), 3, ZAP_ATTRIBUTE_MASK(NULLABLE), ZAP_LONG_DEFAULTS_INDEX(338) }, /* Power */ \ { 0x00000017, ZAP_TYPE(INT32U), 4, ZAP_ATTRIBUTE_MASK(WRITABLE) | ZAP_ATTRIBUTE_MASK(NULLABLE), \ ZAP_LONG_DEFAULTS_INDEX(341) }, /* LifetimeEnergyConsumed */ \ { 0x00000020, ZAP_TYPE(ENUM8), 1, ZAP_ATTRIBUTE_MASK(MIN_MAX) | ZAP_ATTRIBUTE_MASK(WRITABLE), \