Skip to content

Commit a20b8dd

Browse files
bzbarsky-applewoody-applerestyled-commits
authored andcommitted
Add a wildcard attribute read API on MTRDevice. (project-chip#35562)
* Add a wildcard attribute read API on MTRDevice. * Adding new XPC protocol * Restyled by whitespace * Restyled by clang-format * Add unit test for NSCoding bits. * Fix up XPC protocol bits. --------- Co-authored-by: Justin Wood <woody@apple.com> Co-authored-by: Restyled.io <commits@restyled.io>
1 parent d3829ad commit a20b8dd

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

src/darwin/Framework/CHIP/MTRDevice.mm

+11
Original file line numberDiff line numberDiff line change
@@ -1268,6 +1268,17 @@ - (void)writeAttributeWithEndpointID:(NSNumber *)endpointID
12681268
return [NSArray array];
12691269
}
12701270

1271+
- (NSArray<NSDictionary<NSString *, id> *> *)readAttributePaths:(NSArray<MTRAttributeRequestPath *> *)attributePaths
1272+
{
1273+
#define MTRDeviceErrorStr "MTRDevice readAttributePaths: must be handled by subclasses"
1274+
MTR_LOG_ERROR(MTRDeviceErrorStr);
1275+
#ifdef DEBUG
1276+
NSAssert(NO, @MTRDeviceErrorStr);
1277+
#endif // DEBUG
1278+
#undef MTRDeviceErrorStr
1279+
return [NSArray array];
1280+
}
1281+
12711282
- (void)invokeCommandWithEndpointID:(NSNumber *)endpointID
12721283
clusterID:(NSNumber *)clusterID
12731284
commandID:(NSNumber *)commandID

0 commit comments

Comments
 (0)