diff --git a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/MCCluster.mm b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/MCCluster.mm index 7660de0c610017..78414758ec82cb 100644 --- a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/MCCluster.mm +++ b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/MCCluster.mm @@ -15,8 +15,8 @@ * limitations under the License. */ -#import "zap-generated/MCClusterObjects.h" #import "MCCluster_Internal.h" +#import "zap-generated/MCClusterObjects.h" #import "MCEndpoint_Internal.h" diff --git a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/MatterTvCastingBridge.h b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/MatterTvCastingBridge.h index 16ce4a0410be68..19db166102a973 100644 --- a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/MatterTvCastingBridge.h +++ b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/MatterTvCastingBridge.h @@ -27,12 +27,10 @@ FOUNDATION_EXPORT const unsigned char MatterTvCastingBridgeVersionString[]; // Add simplified casting API headers here #import "MCAttribute.h" -#import "zap-generated/MCAttributeObjects.h" #import "MCCastingApp.h" #import "MCCastingPlayer.h" #import "MCCastingPlayerDiscovery.h" #import "MCCluster.h" -#import "zap-generated/MCClusterObjects.h" #import "MCCommand.h" #import "MCCommandObjects.h" #import "MCCommissionableData.h" @@ -42,3 +40,5 @@ FOUNDATION_EXPORT const unsigned char MatterTvCastingBridgeVersionString[]; #import "MCEndpointClusterType.h" #import "MCEndpointFilter.h" #import "MCObserver.h" +#import "zap-generated/MCAttributeObjects.h" +#import "zap-generated/MCClusterObjects.h" diff --git a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/templates/config-data.yaml b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/templates/config-data.yaml index 2567306d5cb5e0..b45974c3596d0a 100644 --- a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/templates/config-data.yaml +++ b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/templates/config-data.yaml @@ -33,4 +33,4 @@ MatterCastingClusters: # The commands currently implemented for Matter Casting in MCCommandObjects.h/mm. We will ZAP generate this file in the next PR. MatterCastingImplementedCommands: - - LaunchURL \ No newline at end of file + - LaunchURL diff --git a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/templates/templates.json b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/templates/templates.json index b746adbd625967..881ac388a1be83 100644 --- a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/templates/templates.json +++ b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/templates/templates.json @@ -47,4 +47,4 @@ "output": "examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/zap-generated/MCClusterObjects.mm" } ] -} \ No newline at end of file +} diff --git a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/zap-generated/MCAttributeObjects.h b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/zap-generated/MCAttributeObjects.h index 6f15e77447e914..81184fe023ffcb 100644 --- a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/zap-generated/MCAttributeObjects.h +++ b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/zap-generated/MCAttributeObjects.h @@ -343,4 +343,4 @@ @interface MCApplicationBasicClusterClusterRevisionAttribute : MCAttribute @end -#endif /* MCAttributeObjects_h */ \ No newline at end of file +#endif /* MCAttributeObjects_h */ diff --git a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/zap-generated/MCClusterObjects.h b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/zap-generated/MCClusterObjects.h index 7593df0ebe1331..683de5283682cd 100644 --- a/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/zap-generated/MCClusterObjects.h +++ b/examples/tv-casting-app/darwin/MatterTvCastingBridge/MatterTvCastingBridge/zap-generated/MCClusterObjects.h @@ -611,4 +611,4 @@ - (MCApplicationBasicClusterClusterRevisionAttribute * _Nullable)clusterRevisionAttribute; @end -#endif /* MCClusterObjects_h */ \ No newline at end of file +#endif /* MCClusterObjects_h */ diff --git a/examples/tv-casting-app/tv-casting-common/core/Attribute.h b/examples/tv-casting-app/tv-casting-common/core/Attribute.h index 2adc004cb782d6..958c7ab24bce9b 100644 --- a/examples/tv-casting-app/tv-casting-common/core/Attribute.h +++ b/examples/tv-casting-app/tv-casting-common/core/Attribute.h @@ -27,8 +27,8 @@ namespace casting { namespace core { template -using ReadResponseSuccessCallbackFn = - std::function before, typename TypeInfo::DecodableArgType after)>; +using ReadResponseSuccessCallbackFn = std::function before, + typename TypeInfo::DecodableArgType after)>; using ReadResponseFailureCallbackFn = std::function; using WriteResponseSuccessCallbackFn = std::function; using WriteResponseFailureCallbackFn = std::function; @@ -72,8 +72,7 @@ class Attribute * before (if the Attribute had been previously read) * @param failureCb Called when there is a failure in reading the Attribute */ - void Read(void * context, ReadResponseSuccessCallbackFn successCb, - ReadResponseFailureCallbackFn failureCb) + void Read(void * context, ReadResponseSuccessCallbackFn successCb, ReadResponseFailureCallbackFn failureCb) { memory::Strong endpoint = this->GetEndpoint().lock(); if (endpoint) @@ -85,8 +84,7 @@ class Attribute attributeContext, // FindOrEstablishSession success handler [](void * _context, chip::Messaging::ExchangeManager & exchangeMgr, const chip::SessionHandle & sessionHandle) { - ReadAttributeContext * _attributeContext = - static_cast *>(_context); + ReadAttributeContext * _attributeContext = static_cast *>(_context); ChipLogProgress(AppServer, "::Read() Found or established session"); // Read attribute @@ -137,8 +135,7 @@ class Attribute }, // FindOrEstablishSession failure handler [](void * _context, const chip::ScopedNodeId & peerId, CHIP_ERROR error) { - ReadAttributeContext * _attributeContext = - static_cast *>(_context); + ReadAttributeContext * _attributeContext = static_cast *>(_context); ChipLogError(AppServer, "::Read() failure in retrieving session info for peerId.nodeId: " "0x" ChipLogFormatX64 ", peer.fabricIndex: %d with error: %" CHIP_ERROR_FORMAT, @@ -245,15 +242,14 @@ class Attribute * @param minIntervalFloorSeconds the requested minimum interval boundary floor in seconds for attribute udpates * @param maxIntervalCeilingSeconds the requested maximum interval boundary ceiling in seconds for attribute udpates */ - void Subscribe(void * context, ReadResponseSuccessCallbackFn successCb, - ReadResponseFailureCallbackFn failureCb, uint16_t minIntervalFloorSeconds, uint16_t maxIntervalCeilingSeconds) + void Subscribe(void * context, ReadResponseSuccessCallbackFn successCb, ReadResponseFailureCallbackFn failureCb, + uint16_t minIntervalFloorSeconds, uint16_t maxIntervalCeilingSeconds) { memory::Strong endpoint = this->GetEndpoint().lock(); if (endpoint) { - SubscribeAttributeContext * attributeContext = - new SubscribeAttributeContext(this, endpoint, context, successCb, failureCb, - minIntervalFloorSeconds, maxIntervalCeilingSeconds); + SubscribeAttributeContext * attributeContext = new SubscribeAttributeContext( + this, endpoint, context, successCb, failureCb, minIntervalFloorSeconds, maxIntervalCeilingSeconds); endpoint->GetCastingPlayer()->FindOrEstablishSession( attributeContext, @@ -385,9 +381,8 @@ template struct SubscribeAttributeContext { SubscribeAttributeContext(void * attribute, memory::Strong endpoint, void * clientContext, - ReadResponseSuccessCallbackFn successCb, - ReadResponseFailureCallbackFn failureCb, uint16_t minIntervalFloorSeconds, - uint16_t maxIntervalCeilingSeconds) : + ReadResponseSuccessCallbackFn successCb, ReadResponseFailureCallbackFn failureCb, + uint16_t minIntervalFloorSeconds, uint16_t maxIntervalCeilingSeconds) : mEndpoint(endpoint), mClientContext(clientContext), mSuccessCb(successCb), mFailureCb(failureCb) {