Skip to content

Commit

Permalink
Darwin: Tidy up Xcode project file and header naming
Browse files Browse the repository at this point in the history
- Add missing header files to the project file and sort groups
- Align group names / paths better with the file system
- Consistently use "_Internal.h" for internal slice of a header (but only if the base header exists)
  • Loading branch information
ksperling-apple authored and pull[bot] committed Nov 8, 2023
1 parent 963628c commit 2447816
Show file tree
Hide file tree
Showing 19 changed files with 234 additions and 157 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
#import <Foundation/Foundation.h>

#import "MTRBaseDevice.h"
#import "MTRCluster_internal.h"
#import "zap-generated/MTRCallbackBridge_internal.h"
#import "MTRCallbackBridge.h"
#import "MTRCluster_Internal.h"

#include <app/CommandSender.h>
#include <app/ReadClient.h>
Expand Down
4 changes: 2 additions & 2 deletions src/darwin/Framework/CHIP/MTRBaseDevice.mm
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@
#import "MTRAttributeTLVValueDecoder_Internal.h"
#import "MTRBaseDevice_Internal.h"
#import "MTRBaseSubscriptionCallback.h"
#import "MTRCallbackBridgeBase_internal.h"
#import "MTRCallbackBridgeBase.h"
#import "MTRCluster.h"
#import "MTRClusterStateCacheContainer_Internal.h"
#import "MTRCluster_internal.h"
#import "MTRCluster_Internal.h"
#import "MTRError_Internal.h"
#import "MTREventTLVValueDecoder_Internal.h"
#import "MTRLogging_Internal.h"
Expand Down
2 changes: 1 addition & 1 deletion src/darwin/Framework/CHIP/MTRCluster.mm
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/

#import "MTRBaseDevice.h"
#import "MTRCluster_internal.h"
#import "MTRCluster_Internal.h"
#import "NSDataSpanConversion.h"
#import "NSStringSpanConversion.h"

Expand Down
13 changes: 6 additions & 7 deletions src/darwin/Framework/CHIP/templates/MTRBaseClusters-src.zapt
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,14 @@

#import <Foundation/Foundation.h>

#import "MTRClusterStateCacheContainer_Internal.h"
#import "MTRBaseClusters_internal.h"
#import "MTRBaseDevice.h"
#import "MTRBaseClusters_Internal.h"
#import "MTRBaseClusterUtils.h"
#import "MTRBaseDevice_Internal.h"
#import "MTRCallbackBridge_internal.h"
#import "MTRCluster_internal.h"
#import "MTRStructsObjc.h"
#import "MTRCallbackBridge.h"
#import "MTRCluster_Internal.h"
#import "MTRClusterStateCacheContainer_Internal.h"
#import "MTRCommandPayloadsObjc.h"
#import "MTRBaseClustersCpp_Internal.h"
#import "MTRStructsObjc.h"

#include <lib/support/CHIPListUtils.h>
#include <platform/CHIPDeviceLayer.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{> header excludeZapComment=true}}

#import "MTRCallbackBridge_internal.h"
#import "MTRCallbackBridge.h"
#import "MTRStructsObjc.h"
#import "MTRCommandPayloadsObjc.h"

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{{> header excludeZapComment=true}}

#import <Foundation/Foundation.h>
#import "MTRCallbackBridgeBase_internal.h"
#import "MTRCallbackBridgeBase.h"

#include <app/data-model/DecodableList.h>
#include <app/util/im-client-callbacks.h>
Expand Down
9 changes: 4 additions & 5 deletions src/darwin/Framework/CHIP/templates/MTRClusters-src.zapt
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,12 @@
#import <Foundation/Foundation.h>

#import "MTRAsyncCallbackWorkQueue.h"
#import "MTRBaseDevice_internal.h"
#import "MTRBaseDevice_Internal.h"
#import "MTRClusterConstants.h"
#import "MTRClusters_internal.h"
#import "MTRDevice.h"
#import "MTRClusters_Internal.h"
#import "MTRDevice_Internal.h"
#import "MTRCallbackBridge_internal.h"
#import "MTRCluster_internal.h"
#import "MTRCallbackBridge.h"
#import "MTRCluster_Internal.h"
#import "MTRStructsObjc.h"
#import "MTRCommandPayloadsObjc.h"
#import "MTRLogging_Internal.h"
Expand Down
14 changes: 7 additions & 7 deletions src/darwin/Framework/CHIP/templates/templates.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,19 +48,19 @@
],
"templates": [
{
"path": "MTRCallbackBridge_internal.zapt",
"name": "Objc MTRCallbackBridge Internal header",
"output": "src/darwin/Framework/CHIP/zap-generated/MTRCallbackBridge_internal.h"
"path": "MTRCallbackBridge.zapt",
"name": "Objc MTRCallbackBridge header",
"output": "src/darwin/Framework/CHIP/zap-generated/MTRCallbackBridge.h"
},
{
"path": "MTRCallbackBridge-src.zapt",
"name": "Objc MTRCallbackBridge",
"output": "src/darwin/Framework/CHIP/zap-generated/MTRCallbackBridge.mm"
},
{
"path": "MTRBaseClusters_internal.zapt",
"path": "MTRBaseClusters_Internal.zapt",
"name": "Objc ZCL asynchronous API Internal Header",
"output": "src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters_internal.h"
"output": "src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters_Internal.h"
},
{
"path": "MTRBaseClusters.zapt",
Expand All @@ -73,9 +73,9 @@
"output": "src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm"
},
{
"path": "MTRClusters_internal.zapt",
"path": "MTRClusters_Internal.zapt",
"name": "Objc ZCL synchronous API Internal Header",
"output": "src/darwin/Framework/CHIP/zap-generated/MTRClusters_internal.h"
"output": "src/darwin/Framework/CHIP/zap-generated/MTRClusters_Internal.h"
},
{
"path": "MTRClusters.zapt",
Expand Down
9 changes: 4 additions & 5 deletions src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 4 additions & 5 deletions src/darwin/Framework/CHIP/zap-generated/MTRClusters.mm

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 2447816

Please sign in to comment.