Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add attributePath parameter to Door Lock Server's unhandledAttributeC… #20338

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/app/clusters/door-lock-server/door-lock-server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3576,7 +3576,7 @@ MatterDoorLockClusterServerPreAttributeChangedCallback(const chip::app::Concrete
break;

default:
res = emberAfPluginDoorLockOnUnhandledAttributeChange(attributePath.mEndpointId, attributeType, size, value);
res = emberAfPluginDoorLockOnUnhandledAttributeChange(attributePath.mEndpointId, attributePath, attributeType, size, value);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jrhees-cae @tcarmelveilleux @woody-apple Why are we still passing the endpoint id separately, as well as in the path?

break;
}

Expand Down Expand Up @@ -3666,8 +3666,8 @@ emberAfPluginDoorLockOnUserCodeTemporaryDisableTimeChange(chip::EndpointId Endpo
}

chip::Protocols::InteractionModel::Status __attribute__((weak))
emberAfPluginDoorLockOnUnhandledAttributeChange(chip::EndpointId EndpointId, EmberAfAttributeType attrType, uint16_t attrSize,
uint8_t * attrValue)
emberAfPluginDoorLockOnUnhandledAttributeChange(chip::EndpointId EndpointId, const chip::app::ConcreteAttributePath & attributePath,
EmberAfAttributeType attrType, uint16_t attrSize, uint8_t * attrValue)
{
return chip::Protocols::InteractionModel::Status::Success;
}
Expand Down
7 changes: 4 additions & 3 deletions src/app/clusters/door-lock-server/door-lock-server.h
Original file line number Diff line number Diff line change
Expand Up @@ -738,16 +738,17 @@ chip::Protocols::InteractionModel::Status emberAfPluginDoorLockOnUserCodeTempora
* @brief Cluster attribute pre-change callback
*
* @param EndpointId endpoint for which attribute is changing
* @param attributePath concrete attribute path that is changing
* @param attrType attribute that is going to be changed
* @param attrSize attribute value storage size
* @param attrValue attribute value to set
*
* @retval InteractionModel::Status::Success if attribute change is possible
* @retval any other InteractionModel::Status value to forbid attribute change
*/
chip::Protocols::InteractionModel::Status emberAfPluginDoorLockOnUnhandledAttributeChange(chip::EndpointId EndpointId,
EmberAfAttributeType attrType,
uint16_t attrSize, uint8_t * attrValue);
chip::Protocols::InteractionModel::Status
emberAfPluginDoorLockOnUnhandledAttributeChange(chip::EndpointId EndpointId, const chip::app::ConcreteAttributePath & attributePath,
EmberAfAttributeType attrType, uint16_t attrSize, uint8_t * attrValue);

// =============================================================================
// Plugin callbacks that are called by cluster server and should be implemented
Expand Down