From a505366162b027dd1f15edafa506f30b22cec399 Mon Sep 17 00:00:00 2001 From: Derek Clarkson Date: Tue, 7 Jun 2016 22:38:13 +1000 Subject: [PATCH 1/7] Creating project for carthage builds. --- .DS_Store | Bin 0 -> 6148 bytes .gitignore | 1 + Cartfile | 6 + Cartfile.resolved | 4 + CocoaUPnP.xcodeproj/project.pbxproj | 619 ++++++++++++++++++ .../contents.xcworkspacedata | 7 + .../xcshareddata/xcschemes/CocoaUPnP.xcscheme | 80 +++ Info.plist | 26 + 8 files changed, 743 insertions(+) create mode 100644 .DS_Store create mode 100644 Cartfile create mode 100644 Cartfile.resolved create mode 100644 CocoaUPnP.xcodeproj/project.pbxproj create mode 100644 CocoaUPnP.xcodeproj/project.xcworkspace/contents.xcworkspacedata create mode 100644 CocoaUPnP.xcodeproj/xcshareddata/xcschemes/CocoaUPnP.xcscheme create mode 100644 Info.plist diff --git a/.DS_Store b/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..9499f2294a89ca78564f7d99cb55f4c0e8549874 GIT binary patch literal 6148 zcmeHKu}T9$5PhR50ycqISnd}HDeRAU_Cl~%?j$0fcSr&j7WWH&o4??P_-1CK30@H! z5t)J6w>z`5xBEhNb^yqHUC)3CfH753v@;-T9&{b#$s?lJ8aKGYB_64#0}K5{lkR;k!N4a2dOswpVv(_Tw5x-Sl>kJ2Mw_s2 zZ%txS1F^{1JJLcC4<&l2l zfkPioH2+`lFF9D`?}o%E7zhUb83QsZ7v-FX%DMI1@if;a>NQnG=k?m5uy3iDXsMV3 hy+=;W>HegB`iqRcqpqTM3n#`yzzB&Z82AMSJ^;o1J30UW literal 0 HcmV?d00001 diff --git a/.gitignore b/.gitignore index ae12729..ab4b193 100644 --- a/.gitignore +++ b/.gitignore @@ -42,3 +42,4 @@ docs/ # Fastlane fastlane/report.xml fastlane/test_output +Carthage diff --git a/Cartfile b/Cartfile new file mode 100644 index 0000000..0c268cf --- /dev/null +++ b/Cartfile @@ -0,0 +1,6 @@ + +github "drekka/Ono" "develop" + +github "robbiehanson/CocoaAsyncSocket" +github "AFNetworking/AFNetworking" +github "swisspol/GCDWebServer" \ No newline at end of file diff --git a/Cartfile.resolved b/Cartfile.resolved new file mode 100644 index 0000000..a591f83 --- /dev/null +++ b/Cartfile.resolved @@ -0,0 +1,4 @@ +github "AFNetworking/AFNetworking" "3.1.0" +github "robbiehanson/CocoaAsyncSocket" "7.4.3" +github "swisspol/GCDWebServer" "3.3.2" +github "drekka/Ono" "67259eb5ed591564149156d88eee38a4669fb183" diff --git a/CocoaUPnP.xcodeproj/project.pbxproj b/CocoaUPnP.xcodeproj/project.pbxproj new file mode 100644 index 0000000..f06e3e7 --- /dev/null +++ b/CocoaUPnP.xcodeproj/project.pbxproj @@ -0,0 +1,619 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 46; + objects = { + +/* Begin PBXBuildFile section */ + 6C3EE80F1D06EE1400506613 /* UPPEventServer.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7C51D06EE1400506613 /* UPPEventServer.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8101D06EE1400506613 /* UPPEventServer.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7C61D06EE1400506613 /* UPPEventServer.m */; }; + 6C3EE8111D06EE1400506613 /* UPPEventSubscription.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7C71D06EE1400506613 /* UPPEventSubscription.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8121D06EE1400506613 /* UPPEventSubscription.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7C81D06EE1400506613 /* UPPEventSubscription.m */; }; + 6C3EE8131D06EE1400506613 /* UPPEventSubscriptionManager.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7C91D06EE1400506613 /* UPPEventSubscriptionManager.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8141D06EE1400506613 /* UPPEventSubscriptionManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7CA1D06EE1400506613 /* UPPEventSubscriptionManager.m */; }; + 6C3EE8151D06EE1400506613 /* NSArray+firstObjectMatchingPredicate.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7CC1D06EE1400506613 /* NSArray+firstObjectMatchingPredicate.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8161D06EE1400506613 /* NSArray+firstObjectMatchingPredicate.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7CD1D06EE1400506613 /* NSArray+firstObjectMatchingPredicate.m */; }; + 6C3EE8171D06EE1400506613 /* NSMutableString+xmlNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7CE1D06EE1400506613 /* NSMutableString+xmlNode.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8181D06EE1400506613 /* NSMutableString+xmlNode.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7CF1D06EE1400506613 /* NSMutableString+xmlNode.m */; }; + 6C3EE8191D06EE1400506613 /* UPPMetadataHelper.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7D01D06EE1400506613 /* UPPMetadataHelper.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE81A1D06EE1400506613 /* UPPMetadataHelper.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7D11D06EE1400506613 /* UPPMetadataHelper.m */; }; + 6C3EE81B1D06EE1400506613 /* UPPBasicDevice.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7D31D06EE1400506613 /* UPPBasicDevice.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE81C1D06EE1400506613 /* UPPBasicDevice.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7D41D06EE1400506613 /* UPPBasicDevice.m */; }; + 6C3EE81D1D06EE1400506613 /* UPPConstants.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7D51D06EE1400506613 /* UPPConstants.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE81E1D06EE1400506613 /* UPPConstants.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7D61D06EE1400506613 /* UPPConstants.m */; }; + 6C3EE81F1D06EE1400506613 /* UPPDeviceIcon.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7D71D06EE1400506613 /* UPPDeviceIcon.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8201D06EE1400506613 /* UPPDeviceIcon.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7D81D06EE1400506613 /* UPPDeviceIcon.m */; }; + 6C3EE8211D06EE1400506613 /* UPPError.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7D91D06EE1400506613 /* UPPError.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8221D06EE1400506613 /* UPPError.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7DA1D06EE1400506613 /* UPPError.m */; }; + 6C3EE8231D06EE1400506613 /* UPPMediaItem.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7DB1D06EE1400506613 /* UPPMediaItem.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8241D06EE1400506613 /* UPPMediaItem.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7DC1D06EE1400506613 /* UPPMediaItem.m */; }; + 6C3EE8251D06EE1400506613 /* UPPMediaItemResource.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7DD1D06EE1400506613 /* UPPMediaItemResource.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8261D06EE1400506613 /* UPPMediaItemResource.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7DE1D06EE1400506613 /* UPPMediaItemResource.m */; }; + 6C3EE8271D06EE1400506613 /* UPPMediaRendererDevice.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7DF1D06EE1400506613 /* UPPMediaRendererDevice.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8281D06EE1400506613 /* UPPMediaRendererDevice.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7E01D06EE1400506613 /* UPPMediaRendererDevice.m */; }; + 6C3EE8291D06EE1400506613 /* UPPMediaServerDevice.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7E11D06EE1400506613 /* UPPMediaServerDevice.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE82A1D06EE1400506613 /* UPPMediaServerDevice.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7E21D06EE1400506613 /* UPPMediaServerDevice.m */; }; + 6C3EE82B1D06EE1400506613 /* UPPParameters.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7E31D06EE1400506613 /* UPPParameters.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE82C1D06EE1400506613 /* UPPParameters.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7E41D06EE1400506613 /* UPPParameters.m */; }; + 6C3EE82D1D06EE1400506613 /* UPPServiceDescription.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7E51D06EE1400506613 /* UPPServiceDescription.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE82E1D06EE1400506613 /* UPPServiceDescription.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7E61D06EE1400506613 /* UPPServiceDescription.m */; }; + 6C3EE82F1D06EE1400506613 /* SSDPService.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7E91D06EE1400506613 /* SSDPService.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8301D06EE1400506613 /* SSDPService.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7EA1D06EE1400506613 /* SSDPService.m */; }; + 6C3EE8311D06EE1400506613 /* SSDPServiceBrowser.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7EB1D06EE1400506613 /* SSDPServiceBrowser.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8321D06EE1400506613 /* SSDPServiceBrowser.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7EC1D06EE1400506613 /* SSDPServiceBrowser.m */; }; + 6C3EE8331D06EE1400506613 /* UPPDiscovery.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7ED1D06EE1400506613 /* UPPDiscovery.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8341D06EE1400506613 /* UPPDiscovery.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7EE1D06EE1400506613 /* UPPDiscovery.m */; }; + 6C3EE8351D06EE1400506613 /* UPPRequestSerializer.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7EF1D06EE1400506613 /* UPPRequestSerializer.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8361D06EE1400506613 /* UPPRequestSerializer.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7F01D06EE1400506613 /* UPPRequestSerializer.m */; }; + 6C3EE8371D06EE1400506613 /* UPPResponseSerializer.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7F11D06EE1400506613 /* UPPResponseSerializer.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8381D06EE1400506613 /* UPPResponseSerializer.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7F21D06EE1400506613 /* UPPResponseSerializer.m */; }; + 6C3EE8391D06EE1400506613 /* UPPSessionManager.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7F31D06EE1400506613 /* UPPSessionManager.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE83A1D06EE1400506613 /* UPPSessionManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7F41D06EE1400506613 /* UPPSessionManager.m */; }; + 6C3EE83B1D06EE1400506613 /* UPPBaseParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7F61D06EE1400506613 /* UPPBaseParser.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE83C1D06EE1400506613 /* UPPBaseParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7F71D06EE1400506613 /* UPPBaseParser.m */; }; + 6C3EE83D1D06EE1400506613 /* UPPDeviceParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7F81D06EE1400506613 /* UPPDeviceParser.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE83E1D06EE1400506613 /* UPPDeviceParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7F91D06EE1400506613 /* UPPDeviceParser.m */; }; + 6C3EE83F1D06EE1400506613 /* UPPErrorParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7FA1D06EE1400506613 /* UPPErrorParser.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8401D06EE1400506613 /* UPPErrorParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7FB1D06EE1400506613 /* UPPErrorParser.m */; }; + 6C3EE8411D06EE1400506613 /* UPPLastChangeParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7FC1D06EE1400506613 /* UPPLastChangeParser.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8421D06EE1400506613 /* UPPLastChangeParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7FD1D06EE1400506613 /* UPPLastChangeParser.m */; }; + 6C3EE8431D06EE1400506613 /* UPPMediaItemParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7FE1D06EE1400506613 /* UPPMediaItemParser.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8441D06EE1400506613 /* UPPMediaItemParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7FF1D06EE1400506613 /* UPPMediaItemParser.m */; }; + 6C3EE8451D06EE1400506613 /* UPPResponseParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE8001D06EE1400506613 /* UPPResponseParser.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8461D06EE1400506613 /* UPPResponseParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE8011D06EE1400506613 /* UPPResponseParser.m */; }; + 6C3EE8471D06EE1400506613 /* UPPMediaItemProtocol.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE8031D06EE1400506613 /* UPPMediaItemProtocol.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8481D06EE1400506613 /* UPPAVTransportService.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE8051D06EE1400506613 /* UPPAVTransportService.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8491D06EE1400506613 /* UPPAVTransportService.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE8061D06EE1400506613 /* UPPAVTransportService.m */; }; + 6C3EE84A1D06EE1400506613 /* UPPBasicService.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE8071D06EE1400506613 /* UPPBasicService.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE84B1D06EE1400506613 /* UPPBasicService.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE8081D06EE1400506613 /* UPPBasicService.m */; }; + 6C3EE84C1D06EE1400506613 /* UPPConnectionManagerService.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE8091D06EE1400506613 /* UPPConnectionManagerService.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE84D1D06EE1400506613 /* UPPConnectionManagerService.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE80A1D06EE1400506613 /* UPPConnectionManagerService.m */; }; + 6C3EE84E1D06EE1400506613 /* UPPContentDirectoryService.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE80B1D06EE1400506613 /* UPPContentDirectoryService.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE84F1D06EE1400506613 /* UPPContentDirectoryService.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE80C1D06EE1400506613 /* UPPContentDirectoryService.m */; }; + 6C3EE8501D06EE1400506613 /* UPPRenderingControlService.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE80D1D06EE1400506613 /* UPPRenderingControlService.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8511D06EE1400506613 /* UPPRenderingControlService.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE80E1D06EE1400506613 /* UPPRenderingControlService.m */; }; + 6CA6C7761D06ED8800BA8CF1 /* CocoaUPnP.h in Headers */ = {isa = PBXBuildFile; fileRef = 6CA6C7751D06ED8800BA8CF1 /* CocoaUPnP.h */; settings = {ATTRIBUTES = (Public, ); }; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + 6C3EE7C51D06EE1400506613 /* UPPEventServer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPEventServer.h; sourceTree = ""; }; + 6C3EE7C61D06EE1400506613 /* UPPEventServer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPEventServer.m; sourceTree = ""; }; + 6C3EE7C71D06EE1400506613 /* UPPEventSubscription.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPEventSubscription.h; sourceTree = ""; }; + 6C3EE7C81D06EE1400506613 /* UPPEventSubscription.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPEventSubscription.m; sourceTree = ""; }; + 6C3EE7C91D06EE1400506613 /* UPPEventSubscriptionManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPEventSubscriptionManager.h; sourceTree = ""; }; + 6C3EE7CA1D06EE1400506613 /* UPPEventSubscriptionManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPEventSubscriptionManager.m; sourceTree = ""; }; + 6C3EE7CC1D06EE1400506613 /* NSArray+firstObjectMatchingPredicate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSArray+firstObjectMatchingPredicate.h"; sourceTree = ""; }; + 6C3EE7CD1D06EE1400506613 /* NSArray+firstObjectMatchingPredicate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSArray+firstObjectMatchingPredicate.m"; sourceTree = ""; }; + 6C3EE7CE1D06EE1400506613 /* NSMutableString+xmlNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSMutableString+xmlNode.h"; sourceTree = ""; }; + 6C3EE7CF1D06EE1400506613 /* NSMutableString+xmlNode.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSMutableString+xmlNode.m"; sourceTree = ""; }; + 6C3EE7D01D06EE1400506613 /* UPPMetadataHelper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPMetadataHelper.h; sourceTree = ""; }; + 6C3EE7D11D06EE1400506613 /* UPPMetadataHelper.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPMetadataHelper.m; sourceTree = ""; }; + 6C3EE7D31D06EE1400506613 /* UPPBasicDevice.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPBasicDevice.h; sourceTree = ""; }; + 6C3EE7D41D06EE1400506613 /* UPPBasicDevice.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPBasicDevice.m; sourceTree = ""; }; + 6C3EE7D51D06EE1400506613 /* UPPConstants.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPConstants.h; sourceTree = ""; }; + 6C3EE7D61D06EE1400506613 /* UPPConstants.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPConstants.m; sourceTree = ""; }; + 6C3EE7D71D06EE1400506613 /* UPPDeviceIcon.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPDeviceIcon.h; sourceTree = ""; }; + 6C3EE7D81D06EE1400506613 /* UPPDeviceIcon.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPDeviceIcon.m; sourceTree = ""; }; + 6C3EE7D91D06EE1400506613 /* UPPError.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPError.h; sourceTree = ""; }; + 6C3EE7DA1D06EE1400506613 /* UPPError.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPError.m; sourceTree = ""; }; + 6C3EE7DB1D06EE1400506613 /* UPPMediaItem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPMediaItem.h; sourceTree = ""; }; + 6C3EE7DC1D06EE1400506613 /* UPPMediaItem.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPMediaItem.m; sourceTree = ""; }; + 6C3EE7DD1D06EE1400506613 /* UPPMediaItemResource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPMediaItemResource.h; sourceTree = ""; }; + 6C3EE7DE1D06EE1400506613 /* UPPMediaItemResource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPMediaItemResource.m; sourceTree = ""; }; + 6C3EE7DF1D06EE1400506613 /* UPPMediaRendererDevice.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPMediaRendererDevice.h; sourceTree = ""; }; + 6C3EE7E01D06EE1400506613 /* UPPMediaRendererDevice.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPMediaRendererDevice.m; sourceTree = ""; }; + 6C3EE7E11D06EE1400506613 /* UPPMediaServerDevice.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPMediaServerDevice.h; sourceTree = ""; }; + 6C3EE7E21D06EE1400506613 /* UPPMediaServerDevice.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPMediaServerDevice.m; sourceTree = ""; }; + 6C3EE7E31D06EE1400506613 /* UPPParameters.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPParameters.h; sourceTree = ""; }; + 6C3EE7E41D06EE1400506613 /* UPPParameters.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPParameters.m; sourceTree = ""; }; + 6C3EE7E51D06EE1400506613 /* UPPServiceDescription.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPServiceDescription.h; sourceTree = ""; }; + 6C3EE7E61D06EE1400506613 /* UPPServiceDescription.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPServiceDescription.m; sourceTree = ""; }; + 6C3EE7E91D06EE1400506613 /* SSDPService.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSDPService.h; sourceTree = ""; }; + 6C3EE7EA1D06EE1400506613 /* SSDPService.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSDPService.m; sourceTree = ""; }; + 6C3EE7EB1D06EE1400506613 /* SSDPServiceBrowser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSDPServiceBrowser.h; sourceTree = ""; }; + 6C3EE7EC1D06EE1400506613 /* SSDPServiceBrowser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSDPServiceBrowser.m; sourceTree = ""; }; + 6C3EE7ED1D06EE1400506613 /* UPPDiscovery.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPDiscovery.h; sourceTree = ""; }; + 6C3EE7EE1D06EE1400506613 /* UPPDiscovery.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPDiscovery.m; sourceTree = ""; }; + 6C3EE7EF1D06EE1400506613 /* UPPRequestSerializer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPRequestSerializer.h; sourceTree = ""; }; + 6C3EE7F01D06EE1400506613 /* UPPRequestSerializer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPRequestSerializer.m; sourceTree = ""; }; + 6C3EE7F11D06EE1400506613 /* UPPResponseSerializer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPResponseSerializer.h; sourceTree = ""; }; + 6C3EE7F21D06EE1400506613 /* UPPResponseSerializer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPResponseSerializer.m; sourceTree = ""; }; + 6C3EE7F31D06EE1400506613 /* UPPSessionManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPSessionManager.h; sourceTree = ""; }; + 6C3EE7F41D06EE1400506613 /* UPPSessionManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPSessionManager.m; sourceTree = ""; }; + 6C3EE7F61D06EE1400506613 /* UPPBaseParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPBaseParser.h; sourceTree = ""; }; + 6C3EE7F71D06EE1400506613 /* UPPBaseParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPBaseParser.m; sourceTree = ""; }; + 6C3EE7F81D06EE1400506613 /* UPPDeviceParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPDeviceParser.h; sourceTree = ""; }; + 6C3EE7F91D06EE1400506613 /* UPPDeviceParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPDeviceParser.m; sourceTree = ""; }; + 6C3EE7FA1D06EE1400506613 /* UPPErrorParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPErrorParser.h; sourceTree = ""; }; + 6C3EE7FB1D06EE1400506613 /* UPPErrorParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPErrorParser.m; sourceTree = ""; }; + 6C3EE7FC1D06EE1400506613 /* UPPLastChangeParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPLastChangeParser.h; sourceTree = ""; }; + 6C3EE7FD1D06EE1400506613 /* UPPLastChangeParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPLastChangeParser.m; sourceTree = ""; }; + 6C3EE7FE1D06EE1400506613 /* UPPMediaItemParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPMediaItemParser.h; sourceTree = ""; }; + 6C3EE7FF1D06EE1400506613 /* UPPMediaItemParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPMediaItemParser.m; sourceTree = ""; }; + 6C3EE8001D06EE1400506613 /* UPPResponseParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPResponseParser.h; sourceTree = ""; }; + 6C3EE8011D06EE1400506613 /* UPPResponseParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPResponseParser.m; sourceTree = ""; }; + 6C3EE8031D06EE1400506613 /* UPPMediaItemProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPMediaItemProtocol.h; sourceTree = ""; }; + 6C3EE8051D06EE1400506613 /* UPPAVTransportService.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPAVTransportService.h; sourceTree = ""; }; + 6C3EE8061D06EE1400506613 /* UPPAVTransportService.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPAVTransportService.m; sourceTree = ""; }; + 6C3EE8071D06EE1400506613 /* UPPBasicService.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPBasicService.h; sourceTree = ""; }; + 6C3EE8081D06EE1400506613 /* UPPBasicService.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPBasicService.m; sourceTree = ""; }; + 6C3EE8091D06EE1400506613 /* UPPConnectionManagerService.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPConnectionManagerService.h; sourceTree = ""; }; + 6C3EE80A1D06EE1400506613 /* UPPConnectionManagerService.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPConnectionManagerService.m; sourceTree = ""; }; + 6C3EE80B1D06EE1400506613 /* UPPContentDirectoryService.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPContentDirectoryService.h; sourceTree = ""; }; + 6C3EE80C1D06EE1400506613 /* UPPContentDirectoryService.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPContentDirectoryService.m; sourceTree = ""; }; + 6C3EE80D1D06EE1400506613 /* UPPRenderingControlService.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPRenderingControlService.h; sourceTree = ""; }; + 6C3EE80E1D06EE1400506613 /* UPPRenderingControlService.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPRenderingControlService.m; sourceTree = ""; }; + 6C3EE8521D06EE8100506613 /* Cartfile */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = Cartfile; sourceTree = ""; }; + 6CA6C7721D06ED8700BA8CF1 /* CocoaUPnP.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = CocoaUPnP.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 6CA6C7751D06ED8800BA8CF1 /* CocoaUPnP.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CocoaUPnP.h; sourceTree = ""; }; + 6CA6C7771D06ED8800BA8CF1 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 6CA6C76E1D06ED8700BA8CF1 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 6C3EE7C41D06EE1400506613 /* Events */ = { + isa = PBXGroup; + children = ( + 6C3EE7C51D06EE1400506613 /* UPPEventServer.h */, + 6C3EE7C61D06EE1400506613 /* UPPEventServer.m */, + 6C3EE7C71D06EE1400506613 /* UPPEventSubscription.h */, + 6C3EE7C81D06EE1400506613 /* UPPEventSubscription.m */, + 6C3EE7C91D06EE1400506613 /* UPPEventSubscriptionManager.h */, + 6C3EE7CA1D06EE1400506613 /* UPPEventSubscriptionManager.m */, + ); + path = Events; + sourceTree = ""; + }; + 6C3EE7CB1D06EE1400506613 /* Helpers */ = { + isa = PBXGroup; + children = ( + 6C3EE7CC1D06EE1400506613 /* NSArray+firstObjectMatchingPredicate.h */, + 6C3EE7CD1D06EE1400506613 /* NSArray+firstObjectMatchingPredicate.m */, + 6C3EE7CE1D06EE1400506613 /* NSMutableString+xmlNode.h */, + 6C3EE7CF1D06EE1400506613 /* NSMutableString+xmlNode.m */, + 6C3EE7D01D06EE1400506613 /* UPPMetadataHelper.h */, + 6C3EE7D11D06EE1400506613 /* UPPMetadataHelper.m */, + ); + path = Helpers; + sourceTree = ""; + }; + 6C3EE7D21D06EE1400506613 /* Models */ = { + isa = PBXGroup; + children = ( + 6C3EE7D31D06EE1400506613 /* UPPBasicDevice.h */, + 6C3EE7D41D06EE1400506613 /* UPPBasicDevice.m */, + 6C3EE7D51D06EE1400506613 /* UPPConstants.h */, + 6C3EE7D61D06EE1400506613 /* UPPConstants.m */, + 6C3EE7D71D06EE1400506613 /* UPPDeviceIcon.h */, + 6C3EE7D81D06EE1400506613 /* UPPDeviceIcon.m */, + 6C3EE7D91D06EE1400506613 /* UPPError.h */, + 6C3EE7DA1D06EE1400506613 /* UPPError.m */, + 6C3EE7DB1D06EE1400506613 /* UPPMediaItem.h */, + 6C3EE7DC1D06EE1400506613 /* UPPMediaItem.m */, + 6C3EE7DD1D06EE1400506613 /* UPPMediaItemResource.h */, + 6C3EE7DE1D06EE1400506613 /* UPPMediaItemResource.m */, + 6C3EE7DF1D06EE1400506613 /* UPPMediaRendererDevice.h */, + 6C3EE7E01D06EE1400506613 /* UPPMediaRendererDevice.m */, + 6C3EE7E11D06EE1400506613 /* UPPMediaServerDevice.h */, + 6C3EE7E21D06EE1400506613 /* UPPMediaServerDevice.m */, + 6C3EE7E31D06EE1400506613 /* UPPParameters.h */, + 6C3EE7E41D06EE1400506613 /* UPPParameters.m */, + 6C3EE7E51D06EE1400506613 /* UPPServiceDescription.h */, + 6C3EE7E61D06EE1400506613 /* UPPServiceDescription.m */, + ); + path = Models; + sourceTree = ""; + }; + 6C3EE7E71D06EE1400506613 /* Networking */ = { + isa = PBXGroup; + children = ( + 6C3EE7E81D06EE1400506613 /* SSDP */, + 6C3EE7ED1D06EE1400506613 /* UPPDiscovery.h */, + 6C3EE7EE1D06EE1400506613 /* UPPDiscovery.m */, + 6C3EE7EF1D06EE1400506613 /* UPPRequestSerializer.h */, + 6C3EE7F01D06EE1400506613 /* UPPRequestSerializer.m */, + 6C3EE7F11D06EE1400506613 /* UPPResponseSerializer.h */, + 6C3EE7F21D06EE1400506613 /* UPPResponseSerializer.m */, + 6C3EE7F31D06EE1400506613 /* UPPSessionManager.h */, + 6C3EE7F41D06EE1400506613 /* UPPSessionManager.m */, + ); + path = Networking; + sourceTree = ""; + }; + 6C3EE7E81D06EE1400506613 /* SSDP */ = { + isa = PBXGroup; + children = ( + 6C3EE7E91D06EE1400506613 /* SSDPService.h */, + 6C3EE7EA1D06EE1400506613 /* SSDPService.m */, + 6C3EE7EB1D06EE1400506613 /* SSDPServiceBrowser.h */, + 6C3EE7EC1D06EE1400506613 /* SSDPServiceBrowser.m */, + ); + path = SSDP; + sourceTree = ""; + }; + 6C3EE7F51D06EE1400506613 /* Parsers */ = { + isa = PBXGroup; + children = ( + 6C3EE7F61D06EE1400506613 /* UPPBaseParser.h */, + 6C3EE7F71D06EE1400506613 /* UPPBaseParser.m */, + 6C3EE7F81D06EE1400506613 /* UPPDeviceParser.h */, + 6C3EE7F91D06EE1400506613 /* UPPDeviceParser.m */, + 6C3EE7FA1D06EE1400506613 /* UPPErrorParser.h */, + 6C3EE7FB1D06EE1400506613 /* UPPErrorParser.m */, + 6C3EE7FC1D06EE1400506613 /* UPPLastChangeParser.h */, + 6C3EE7FD1D06EE1400506613 /* UPPLastChangeParser.m */, + 6C3EE7FE1D06EE1400506613 /* UPPMediaItemParser.h */, + 6C3EE7FF1D06EE1400506613 /* UPPMediaItemParser.m */, + 6C3EE8001D06EE1400506613 /* UPPResponseParser.h */, + 6C3EE8011D06EE1400506613 /* UPPResponseParser.m */, + ); + path = Parsers; + sourceTree = ""; + }; + 6C3EE8021D06EE1400506613 /* Protocols */ = { + isa = PBXGroup; + children = ( + 6C3EE8031D06EE1400506613 /* UPPMediaItemProtocol.h */, + ); + path = Protocols; + sourceTree = ""; + }; + 6C3EE8041D06EE1400506613 /* Services */ = { + isa = PBXGroup; + children = ( + 6C3EE8051D06EE1400506613 /* UPPAVTransportService.h */, + 6C3EE8061D06EE1400506613 /* UPPAVTransportService.m */, + 6C3EE8071D06EE1400506613 /* UPPBasicService.h */, + 6C3EE8081D06EE1400506613 /* UPPBasicService.m */, + 6C3EE8091D06EE1400506613 /* UPPConnectionManagerService.h */, + 6C3EE80A1D06EE1400506613 /* UPPConnectionManagerService.m */, + 6C3EE80B1D06EE1400506613 /* UPPContentDirectoryService.h */, + 6C3EE80C1D06EE1400506613 /* UPPContentDirectoryService.m */, + 6C3EE80D1D06EE1400506613 /* UPPRenderingControlService.h */, + 6C3EE80E1D06EE1400506613 /* UPPRenderingControlService.m */, + ); + path = Services; + sourceTree = ""; + }; + 6CA6C7681D06ED8700BA8CF1 = { + isa = PBXGroup; + children = ( + 6C3EE8521D06EE8100506613 /* Cartfile */, + 6CA6C7771D06ED8800BA8CF1 /* Info.plist */, + 6CA6C7741D06ED8800BA8CF1 /* CocoaUPnP */, + 6CA6C7731D06ED8700BA8CF1 /* Products */, + ); + sourceTree = ""; + }; + 6CA6C7731D06ED8700BA8CF1 /* Products */ = { + isa = PBXGroup; + children = ( + 6CA6C7721D06ED8700BA8CF1 /* CocoaUPnP.framework */, + ); + name = Products; + sourceTree = ""; + }; + 6CA6C7741D06ED8800BA8CF1 /* CocoaUPnP */ = { + isa = PBXGroup; + children = ( + 6C3EE7C41D06EE1400506613 /* Events */, + 6C3EE7CB1D06EE1400506613 /* Helpers */, + 6C3EE7D21D06EE1400506613 /* Models */, + 6C3EE7E71D06EE1400506613 /* Networking */, + 6C3EE7F51D06EE1400506613 /* Parsers */, + 6C3EE8021D06EE1400506613 /* Protocols */, + 6C3EE8041D06EE1400506613 /* Services */, + 6CA6C7751D06ED8800BA8CF1 /* CocoaUPnP.h */, + ); + path = CocoaUPnP; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXHeadersBuildPhase section */ + 6CA6C76F1D06ED8700BA8CF1 /* Headers */ = { + isa = PBXHeadersBuildPhase; + buildActionMask = 2147483647; + files = ( + 6C3EE82F1D06EE1400506613 /* SSDPService.h in Headers */, + 6C3EE83D1D06EE1400506613 /* UPPDeviceParser.h in Headers */, + 6C3EE8371D06EE1400506613 /* UPPResponseSerializer.h in Headers */, + 6C3EE84C1D06EE1400506613 /* UPPConnectionManagerService.h in Headers */, + 6C3EE8111D06EE1400506613 /* UPPEventSubscription.h in Headers */, + 6C3EE80F1D06EE1400506613 /* UPPEventServer.h in Headers */, + 6C3EE8211D06EE1400506613 /* UPPError.h in Headers */, + 6C3EE8351D06EE1400506613 /* UPPRequestSerializer.h in Headers */, + 6C3EE81D1D06EE1400506613 /* UPPConstants.h in Headers */, + 6C3EE8391D06EE1400506613 /* UPPSessionManager.h in Headers */, + 6C3EE84E1D06EE1400506613 /* UPPContentDirectoryService.h in Headers */, + 6C3EE8131D06EE1400506613 /* UPPEventSubscriptionManager.h in Headers */, + 6C3EE8471D06EE1400506613 /* UPPMediaItemProtocol.h in Headers */, + 6C3EE8151D06EE1400506613 /* NSArray+firstObjectMatchingPredicate.h in Headers */, + 6C3EE83B1D06EE1400506613 /* UPPBaseParser.h in Headers */, + 6C3EE8271D06EE1400506613 /* UPPMediaRendererDevice.h in Headers */, + 6CA6C7761D06ED8800BA8CF1 /* CocoaUPnP.h in Headers */, + 6C3EE84A1D06EE1400506613 /* UPPBasicService.h in Headers */, + 6C3EE8311D06EE1400506613 /* SSDPServiceBrowser.h in Headers */, + 6C3EE8451D06EE1400506613 /* UPPResponseParser.h in Headers */, + 6C3EE81B1D06EE1400506613 /* UPPBasicDevice.h in Headers */, + 6C3EE8231D06EE1400506613 /* UPPMediaItem.h in Headers */, + 6C3EE8501D06EE1400506613 /* UPPRenderingControlService.h in Headers */, + 6C3EE8291D06EE1400506613 /* UPPMediaServerDevice.h in Headers */, + 6C3EE81F1D06EE1400506613 /* UPPDeviceIcon.h in Headers */, + 6C3EE8171D06EE1400506613 /* NSMutableString+xmlNode.h in Headers */, + 6C3EE8251D06EE1400506613 /* UPPMediaItemResource.h in Headers */, + 6C3EE82D1D06EE1400506613 /* UPPServiceDescription.h in Headers */, + 6C3EE8331D06EE1400506613 /* UPPDiscovery.h in Headers */, + 6C3EE8431D06EE1400506613 /* UPPMediaItemParser.h in Headers */, + 6C3EE8481D06EE1400506613 /* UPPAVTransportService.h in Headers */, + 6C3EE82B1D06EE1400506613 /* UPPParameters.h in Headers */, + 6C3EE83F1D06EE1400506613 /* UPPErrorParser.h in Headers */, + 6C3EE8191D06EE1400506613 /* UPPMetadataHelper.h in Headers */, + 6C3EE8411D06EE1400506613 /* UPPLastChangeParser.h in Headers */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXHeadersBuildPhase section */ + +/* Begin PBXNativeTarget section */ + 6CA6C7711D06ED8700BA8CF1 /* CocoaUPnP */ = { + isa = PBXNativeTarget; + buildConfigurationList = 6CA6C77A1D06ED8800BA8CF1 /* Build configuration list for PBXNativeTarget "CocoaUPnP" */; + buildPhases = ( + 6CA6C76D1D06ED8700BA8CF1 /* Sources */, + 6CA6C76E1D06ED8700BA8CF1 /* Frameworks */, + 6CA6C76F1D06ED8700BA8CF1 /* Headers */, + 6CA6C7701D06ED8700BA8CF1 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = CocoaUPnP; + productName = CocoaUPnP; + productReference = 6CA6C7721D06ED8700BA8CF1 /* CocoaUPnP.framework */; + productType = "com.apple.product-type.framework"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 6CA6C7691D06ED8700BA8CF1 /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 0730; + ORGANIZATIONNAME = ARCAM; + TargetAttributes = { + 6CA6C7711D06ED8700BA8CF1 = { + CreatedOnToolsVersion = 7.3.1; + }; + }; + }; + buildConfigurationList = 6CA6C76C1D06ED8700BA8CF1 /* Build configuration list for PBXProject "CocoaUPnP" */; + compatibilityVersion = "Xcode 3.2"; + developmentRegion = English; + hasScannedForEncodings = 0; + knownRegions = ( + en, + ); + mainGroup = 6CA6C7681D06ED8700BA8CF1; + productRefGroup = 6CA6C7731D06ED8700BA8CF1 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 6CA6C7711D06ED8700BA8CF1 /* CocoaUPnP */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 6CA6C7701D06ED8700BA8CF1 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 6CA6C76D1D06ED8700BA8CF1 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 6C3EE8491D06EE1400506613 /* UPPAVTransportService.m in Sources */, + 6C3EE8181D06EE1400506613 /* NSMutableString+xmlNode.m in Sources */, + 6C3EE8141D06EE1400506613 /* UPPEventSubscriptionManager.m in Sources */, + 6C3EE8221D06EE1400506613 /* UPPError.m in Sources */, + 6C3EE81A1D06EE1400506613 /* UPPMetadataHelper.m in Sources */, + 6C3EE8401D06EE1400506613 /* UPPErrorParser.m in Sources */, + 6C3EE83C1D06EE1400506613 /* UPPBaseParser.m in Sources */, + 6C3EE81E1D06EE1400506613 /* UPPConstants.m in Sources */, + 6C3EE8261D06EE1400506613 /* UPPMediaItemResource.m in Sources */, + 6C3EE83A1D06EE1400506613 /* UPPSessionManager.m in Sources */, + 6C3EE84B1D06EE1400506613 /* UPPBasicService.m in Sources */, + 6C3EE8341D06EE1400506613 /* UPPDiscovery.m in Sources */, + 6C3EE8301D06EE1400506613 /* SSDPService.m in Sources */, + 6C3EE84F1D06EE1400506613 /* UPPContentDirectoryService.m in Sources */, + 6C3EE8461D06EE1400506613 /* UPPResponseParser.m in Sources */, + 6C3EE8201D06EE1400506613 /* UPPDeviceIcon.m in Sources */, + 6C3EE8361D06EE1400506613 /* UPPRequestSerializer.m in Sources */, + 6C3EE8281D06EE1400506613 /* UPPMediaRendererDevice.m in Sources */, + 6C3EE82C1D06EE1400506613 /* UPPParameters.m in Sources */, + 6C3EE8101D06EE1400506613 /* UPPEventServer.m in Sources */, + 6C3EE8121D06EE1400506613 /* UPPEventSubscription.m in Sources */, + 6C3EE8511D06EE1400506613 /* UPPRenderingControlService.m in Sources */, + 6C3EE8321D06EE1400506613 /* SSDPServiceBrowser.m in Sources */, + 6C3EE8421D06EE1400506613 /* UPPLastChangeParser.m in Sources */, + 6C3EE81C1D06EE1400506613 /* UPPBasicDevice.m in Sources */, + 6C3EE8441D06EE1400506613 /* UPPMediaItemParser.m in Sources */, + 6C3EE82E1D06EE1400506613 /* UPPServiceDescription.m in Sources */, + 6C3EE82A1D06EE1400506613 /* UPPMediaServerDevice.m in Sources */, + 6C3EE84D1D06EE1400506613 /* UPPConnectionManagerService.m in Sources */, + 6C3EE8161D06EE1400506613 /* NSArray+firstObjectMatchingPredicate.m in Sources */, + 6C3EE8381D06EE1400506613 /* UPPResponseSerializer.m in Sources */, + 6C3EE83E1D06EE1400506613 /* UPPDeviceParser.m in Sources */, + 6C3EE8241D06EE1400506613 /* UPPMediaItem.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin XCBuildConfiguration section */ + 6CA6C7781D06ED8800BA8CF1 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + CURRENT_PROJECT_VERSION = 1; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.3; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + VERSIONING_SYSTEM = "apple-generic"; + VERSION_INFO_PREFIX = ""; + }; + name = Debug; + }; + 6CA6C7791D06ED8800BA8CF1 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + CURRENT_PROJECT_VERSION = 1; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.3; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + VERSIONING_SYSTEM = "apple-generic"; + VERSION_INFO_PREFIX = ""; + }; + name = Release; + }; + 6CA6C77B1D06ED8800BA8CF1 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + INFOPLIST_FILE = "$(SRCROOT)/Info.plist"; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = uk.com.arcam.cocoaupnp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SKIP_INSTALL = YES; + }; + name = Debug; + }; + 6CA6C77C1D06ED8800BA8CF1 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + INFOPLIST_FILE = "$(SRCROOT)/Info.plist"; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = uk.com.arcam.cocoaupnp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SKIP_INSTALL = YES; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 6CA6C76C1D06ED8700BA8CF1 /* Build configuration list for PBXProject "CocoaUPnP" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 6CA6C7781D06ED8800BA8CF1 /* Debug */, + 6CA6C7791D06ED8800BA8CF1 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 6CA6C77A1D06ED8800BA8CF1 /* Build configuration list for PBXNativeTarget "CocoaUPnP" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 6CA6C77B1D06ED8800BA8CF1 /* Debug */, + 6CA6C77C1D06ED8800BA8CF1 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 6CA6C7691D06ED8700BA8CF1 /* Project object */; +} diff --git a/CocoaUPnP.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/CocoaUPnP.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..04351f3 --- /dev/null +++ b/CocoaUPnP.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/CocoaUPnP.xcodeproj/xcshareddata/xcschemes/CocoaUPnP.xcscheme b/CocoaUPnP.xcodeproj/xcshareddata/xcschemes/CocoaUPnP.xcscheme new file mode 100644 index 0000000..e71acd8 --- /dev/null +++ b/CocoaUPnP.xcodeproj/xcshareddata/xcschemes/CocoaUPnP.xcscheme @@ -0,0 +1,80 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Info.plist b/Info.plist new file mode 100644 index 0000000..d3de8ee --- /dev/null +++ b/Info.plist @@ -0,0 +1,26 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + $(CURRENT_PROJECT_VERSION) + NSPrincipalClass + + + From 4d6ec18d388658876c50ba29b0ced98e95e15f36 Mon Sep 17 00:00:00 2001 From: Derek Clarkson Date: Tue, 7 Jun 2016 23:04:43 +1000 Subject: [PATCH 2/7] Fixing completion and import issues. --- .DS_Store | Bin 6148 -> 6148 bytes CocoaUPnP.xcodeproj/project.pbxproj | 24 +++++ CocoaUPnP/Events/UPPEventServer.h | 2 +- CocoaUPnP/Events/UPPEventServer.m | 12 +-- .../Events/UPPEventSubscriptionManager.m | 100 +++++++++--------- CocoaUPnP/Models/UPPConstants.m | 2 + .../Networking/SSDP/SSDPServiceBrowser.m | 68 ++++++------ CocoaUPnP/Parsers/UPPDeviceParser.m | 37 +++---- CocoaUPnP/Parsers/UPPErrorParser.m | 10 +- CocoaUPnP/Parsers/UPPLastChangeParser.m | 2 +- CocoaUPnP/Parsers/UPPMediaItemParser.m | 44 ++++---- CocoaUPnP/Parsers/UPPResponseParser.m | 26 ++--- 12 files changed, 179 insertions(+), 148 deletions(-) diff --git a/.DS_Store b/.DS_Store index 9499f2294a89ca78564f7d99cb55f4c0e8549874..58d20a5574c61bf9c8e901ced0a0004ad04b2ea2 100644 GIT binary patch delta 63 zcmZoMXffE}%*f2hVLiElQHRIHC8e|^nStSQP0^Rhb&M8FU`mIhAj2>?IX|~x^Lr6d Q=FI|3Y|NY4IsWnk0D*iIN&o-= delta 68 zcmZoMXffE}%*f2}#B_24qYjUYOG;@;G6Tcqn)Hd2>liJV(nWxj4u3(0VQ_MOZUF-b UFbZsDWMX5R*ub}$o#QV*0K-KSBLDyZ diff --git a/CocoaUPnP.xcodeproj/project.pbxproj b/CocoaUPnP.xcodeproj/project.pbxproj index f06e3e7..5de9e0a 100644 --- a/CocoaUPnP.xcodeproj/project.pbxproj +++ b/CocoaUPnP.xcodeproj/project.pbxproj @@ -74,6 +74,10 @@ 6C3EE84F1D06EE1400506613 /* UPPContentDirectoryService.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE80C1D06EE1400506613 /* UPPContentDirectoryService.m */; }; 6C3EE8501D06EE1400506613 /* UPPRenderingControlService.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE80D1D06EE1400506613 /* UPPRenderingControlService.h */; settings = {ATTRIBUTES = (Public, ); }; }; 6C3EE8511D06EE1400506613 /* UPPRenderingControlService.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE80E1D06EE1400506613 /* UPPRenderingControlService.m */; }; + 6C3EE86C1D06F9F400506613 /* AFNetworking.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6C3EE8681D06F9F400506613 /* AFNetworking.framework */; }; + 6C3EE86D1D06F9F400506613 /* CocoaAsyncSocket.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6C3EE8691D06F9F400506613 /* CocoaAsyncSocket.framework */; }; + 6C3EE86E1D06F9F400506613 /* GCDWebServers.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6C3EE86A1D06F9F400506613 /* GCDWebServers.framework */; }; + 6C3EE86F1D06F9F400506613 /* Ono.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6C3EE86B1D06F9F400506613 /* Ono.framework */; }; 6CA6C7761D06ED8800BA8CF1 /* CocoaUPnP.h in Headers */ = {isa = PBXBuildFile; fileRef = 6CA6C7751D06ED8800BA8CF1 /* CocoaUPnP.h */; settings = {ATTRIBUTES = (Public, ); }; }; /* End PBXBuildFile section */ @@ -146,6 +150,10 @@ 6C3EE80D1D06EE1400506613 /* UPPRenderingControlService.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPRenderingControlService.h; sourceTree = ""; }; 6C3EE80E1D06EE1400506613 /* UPPRenderingControlService.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPRenderingControlService.m; sourceTree = ""; }; 6C3EE8521D06EE8100506613 /* Cartfile */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = Cartfile; sourceTree = ""; }; + 6C3EE8681D06F9F400506613 /* AFNetworking.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AFNetworking.framework; path = Carthage/Build/iOS/AFNetworking.framework; sourceTree = ""; }; + 6C3EE8691D06F9F400506613 /* CocoaAsyncSocket.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CocoaAsyncSocket.framework; path = Carthage/Build/iOS/CocoaAsyncSocket.framework; sourceTree = ""; }; + 6C3EE86A1D06F9F400506613 /* GCDWebServers.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = GCDWebServers.framework; path = Carthage/Build/iOS/GCDWebServers.framework; sourceTree = ""; }; + 6C3EE86B1D06F9F400506613 /* Ono.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Ono.framework; path = Carthage/Build/iOS/Ono.framework; sourceTree = ""; }; 6CA6C7721D06ED8700BA8CF1 /* CocoaUPnP.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = CocoaUPnP.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 6CA6C7751D06ED8800BA8CF1 /* CocoaUPnP.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CocoaUPnP.h; sourceTree = ""; }; 6CA6C7771D06ED8800BA8CF1 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; @@ -156,6 +164,10 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( + 6C3EE86C1D06F9F400506613 /* AFNetworking.framework in Frameworks */, + 6C3EE86D1D06F9F400506613 /* CocoaAsyncSocket.framework in Frameworks */, + 6C3EE86E1D06F9F400506613 /* GCDWebServers.framework in Frameworks */, + 6C3EE86F1D06F9F400506613 /* Ono.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -289,6 +301,10 @@ 6CA6C7681D06ED8700BA8CF1 = { isa = PBXGroup; children = ( + 6C3EE8681D06F9F400506613 /* AFNetworking.framework */, + 6C3EE8691D06F9F400506613 /* CocoaAsyncSocket.framework */, + 6C3EE86A1D06F9F400506613 /* GCDWebServers.framework */, + 6C3EE86B1D06F9F400506613 /* Ono.framework */, 6C3EE8521D06EE8100506613 /* Cartfile */, 6CA6C7771D06ED8800BA8CF1 /* Info.plist */, 6CA6C7741D06ED8800BA8CF1 /* CocoaUPnP */, @@ -567,6 +583,10 @@ DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Carthage/Build/iOS", + ); INFOPLIST_FILE = "$(SRCROOT)/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; @@ -583,6 +603,10 @@ DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Carthage/Build/iOS", + ); INFOPLIST_FILE = "$(SRCROOT)/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; diff --git a/CocoaUPnP/Events/UPPEventServer.h b/CocoaUPnP/Events/UPPEventServer.h index ac643c4..3ce9c6f 100644 --- a/CocoaUPnP/Events/UPPEventServer.h +++ b/CocoaUPnP/Events/UPPEventServer.h @@ -2,7 +2,7 @@ // Copyright 2015 Arcam. See LICENSE file. #import -#import +#import /** A delegate protocol for recieving parsed UPnP events. diff --git a/CocoaUPnP/Events/UPPEventServer.m b/CocoaUPnP/Events/UPPEventServer.m index b11ffcc..1351080 100644 --- a/CocoaUPnP/Events/UPPEventServer.m +++ b/CocoaUPnP/Events/UPPEventServer.m @@ -2,7 +2,7 @@ // Copyright 2015 Arcam. See LICENSE file. #import "UPPEventServer.h" -#import "GCDWebServerDataRequest.h" +#import #import "UPPLastChangeParser.h" const NSUInteger UPPEventServerPort = 54123; @@ -18,14 +18,14 @@ @implementation UPPEventServer - (void)startServer { __weak typeof(self) weakSelf = self; - + [self.webServer addHandlerForMethod:@"NOTIFY" path:@"/Event" requestClass:[GCDWebServerDataRequest class] processBlock:^GCDWebServerResponse *(GCDWebServerRequest *request) { if (request != nil) { [weakSelf requestRecieved:(GCDWebServerDataRequest *)request]; } return [[GCDWebServerResponse alloc] init]; }]; - + if ([self.webServer startWithPort:UPPEventServerPort bonjourName:nil]) { NSURL *baseURL = self.webServer.serverURL; self.callbackURL = [baseURL URLByAppendingPathComponent:@"Event"]; @@ -65,18 +65,18 @@ - (void)requestRecieved:(GCDWebServerDataRequest *)request { NSDictionary *headers = request.headers; NSMutableDictionary *eventDictionary = [NSMutableDictionary dictionary]; - + NSString *sid = headers[@"SID"]; if (sid) { [eventDictionary setObject:sid forKey:UPPEventServerSIDKey]; } - + [UPPLastChangeParser parseData:request.data completion:^(NSDictionary *event, NSError *error) { if (event) { eventDictionary[UPPEventServerBodyKey] = event; } }]; - + [self.eventDelegate eventReceived:[eventDictionary copy]]; } diff --git a/CocoaUPnP/Events/UPPEventSubscriptionManager.m b/CocoaUPnP/Events/UPPEventSubscriptionManager.m index 29efa5f..aa2f96a 100644 --- a/CocoaUPnP/Events/UPPEventSubscriptionManager.m +++ b/CocoaUPnP/Events/UPPEventSubscriptionManager.m @@ -1,6 +1,8 @@ // CocoaUPnP by A&R Cambridge Ltd, http://www.arcam.co.uk // Copyright 2015 Arcam. See LICENSE file. +@import UIKit; + #import "UPPEventSubscriptionManager.h" #import "UPPBasicService.h" #import "UPPEventSubscription.h" @@ -17,13 +19,13 @@ @implementation UPPEventSubscriptionManager + (instancetype)sharedManager { static dispatch_once_t onceToken = 0; - + __strong static id _sharedManager = nil; dispatch_once(&onceToken, ^{ NSURLSession *session = [NSURLSession sharedSession]; _sharedManager = [[self alloc] initWithSession:session]; }); - + return _sharedManager; } @@ -33,7 +35,7 @@ - (instancetype)initWithSession:(NSURLSession *)session self.session = session; [self addNotificationObservers]; } - + return self; } @@ -45,12 +47,12 @@ - (void)dealloc - (void)addNotificationObservers { NSNotificationCenter *nc = [NSNotificationCenter defaultCenter]; - + [nc addObserver:self selector:@selector(invalidateAllTimers) name:UIApplicationDidEnterBackgroundNotification object:nil]; - + [nc addObserver:self selector:@selector(renewAllTimers) name:UIApplicationDidBecomeActiveNotification @@ -64,7 +66,7 @@ - (NSMutableArray *)activeSubscriptions if (!_activeSubscriptions) { _activeSubscriptions = [NSMutableArray array]; } - + return _activeSubscriptions; } @@ -73,7 +75,7 @@ - (UPPEventServer *)eventServer if (!_eventServer) { _eventServer = [[UPPEventServer alloc] init]; } - + return _eventServer; } @@ -85,7 +87,7 @@ - (void)subscribeObserver:(id)observer toService:( self.eventServer.eventDelegate = self; [self.eventServer startServer]; } - + // If we already have an existing subscription, add the new observer then // bail out early. UPPEventSubscription *subscription = [self subscriptionWithURL:service.eventSubscriptionURL]; @@ -96,7 +98,7 @@ - (void)subscribeObserver:(id)observer toService:( } return; } - + // Create a new subscription. NSURL *url = service.eventSubscriptionURL; subscription = [UPPEventSubscription subscriptionWithSubscriptionURL:url @@ -121,13 +123,13 @@ - (void)subscribeObserver:(id)observer toService:( - (void)subscribe:(UPPEventSubscription *)subscription completion:(void(^)(NSString *subscriptionID, NSDate *expiryDate, NSError *error))completion { if (!completion) { return; } - + NSURL *url = subscription.eventSubscriptionURL; NSURLRequest *request = [self subscriptionRequestWithEventSubscriptionURL:url]; - + [self sendSubscriptionRequest:request completion:^(NSURLResponse *response, NSError *error) { NSInteger code = [(NSHTTPURLResponse *)response statusCode]; - + if (code != 200) { if (self.activeSubscriptions.count == 0) { [self.eventServer stopServer]; @@ -152,34 +154,34 @@ - (void)renewSubscription:(UPPEventSubscription *)subscription completion:(void( return; } NSURL *subscriptionURL = subscription.eventSubscriptionURL; - + NSDictionary *headers = @{ @"HOST": [subscriptionURL absoluteString], @"SID": [subscription subscriptionID], @"TIMEOUT": @"Second-1800" }; - + NSMutableURLRequest *request = [self requestWithURL:subscriptionURL method:@"SUBSCRIBE" headers:headers]; - + NSURLSessionDataTask *task = [self.session dataTaskWithRequest:request completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) { - + if (!completion) { return; } - + NSInteger code = [(NSHTTPURLResponse *)response statusCode]; - + if (code != 200) { NSError *e = error ?: UPPErrorWithCodeAndDescription(code, @"Renew subscription error"); completion(nil, nil, e); return; } - + NSDictionary *headers = [(NSHTTPURLResponse *)response allHeaderFields]; NSString *subscriptionID = headers[@"SID"]; NSDate *expiryDate = [self dateFromHeader:headers[@"TIMEOUT"]]; - + completion(subscriptionID, expiryDate, nil); }]; - + [task resume]; } @@ -194,18 +196,18 @@ - (NSURLRequest *)subscriptionRequestWithEventSubscriptionURL:(NSURL *)url NSString *host = [NSString stringWithFormat:@"%@:%@", [subscriptionURL host], [subscriptionURL port]]; - + NSURL *callbackURL = [self.eventServer eventServerCallbackURL]; NSString *callback = [NSString stringWithFormat:@"<%@>", [callbackURL absoluteString]]; - + NSDictionary *headers = @{ @"HOST": host, @"USER-AGENT": @"iOS/8.4 UPnP/1.1 Example/1.0", @"CALLBACK": callback, @"NT": @"upnp:event", @"TIMEOUT": @"Second-1800" }; - - + + return [self requestWithURL:url method:@"SUBSCRIBE" headers:headers]; } @@ -213,27 +215,27 @@ - (void)unsubscribe:(UPPEventSubscription *)subscription completion:(void(^)(BOO { [subscription invalidateTimers]; [self.activeSubscriptions removeObject:subscription]; - + if (!subscription.eventSubscriptionURL || !subscription.subscriptionID) { if (completion) { completion(NO); } return; } - + NSURL *subscriptionURL = subscription.eventSubscriptionURL; - + NSDictionary *headers = @{ @"HOST": [subscriptionURL absoluteString], @"SID": [subscription subscriptionID] }; - + NSMutableURLRequest *request = [self requestWithURL:subscriptionURL method:@"UNSUBSCRIBE" headers:headers]; - + NSURLSessionDataTask *task = [self.session dataTaskWithRequest:request completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) { - + NSInteger code = [(NSHTTPURLResponse *)response statusCode]; - + if (code == 200) { - + if (self.activeSubscriptions.count == 0) { [self.eventServer stopServer]; self.eventServer = nil; @@ -247,22 +249,22 @@ - (void)unsubscribe:(UPPEventSubscription *)subscription completion:(void(^)(BOO } } }]; - + [task resume]; } - (void)removeObserver:(id)observer fromService:(UPPBasicService *)service completion:(void (^)(BOOL))completion { UPPEventSubscription *subscripton = [self subscriptionWithURL:service.eventSubscriptionURL]; - + if (subscripton) { [subscripton removeEventObserver:observer]; - + if ([subscripton eventObservers].count == 0) { [self unsubscribe:subscripton completion:nil]; } } - + if (completion) { completion(NO); } @@ -271,18 +273,18 @@ - (void)removeObserver:(id)observer fromService:(U - (void)removeSubscriptionsForServices:(NSArray *)services deviceId:(NSString *)deviceId { NSMutableArray *subscriptions = [NSMutableArray array]; - + for (UPPServiceDescription *service in services) { NSString *identifier = [NSString stringWithFormat:@"%@::%@", deviceId, service.serviceType]; NSArray *objects = [self subscriptionsForServiceIdentifier:identifier]; [subscriptions addObjectsFromArray:objects]; } - + if (subscriptions.count == 0) { return; } - + for (UPPEventSubscription *subscription in subscriptions) { [subscription invalidateTimers]; [self.activeSubscriptions removeObject:subscription]; @@ -297,11 +299,11 @@ - (void)eventReceived:(NSDictionary *)event NSPredicate *predicate = [NSPredicate predicateWithFormat:@"subscriptionID == %@", sid]; UPPEventSubscription *subscription = [self.activeSubscriptions upp_firstObjectMatchingPredicate:predicate]; - + if (!subscription) { return; } - + [subscription informObserversOfEvent:event]; } @@ -325,7 +327,7 @@ - (UPPEventSubscription *)subscriptionWithURL:(NSURL *)url { NSPredicate *predicate = [NSPredicate predicateWithFormat:@"eventSubscriptionURL = %@", url]; NSArray *matches = [self.activeSubscriptions filteredArrayUsingPredicate:predicate]; - + return [matches firstObject]; } @@ -340,10 +342,10 @@ - (NSDate *)dateFromHeader:(NSString *)header if (!header) { return nil; } - + NSString *timeout = [header stringByReplacingOccurrencesOfString:@"Second-" withString:@""]; - + return [NSDate dateWithTimeIntervalSinceNow:[timeout doubleValue]]; } @@ -351,13 +353,13 @@ - (void)sendSubscriptionRequest:(NSURLRequest *)request completion:(void (^)(NSU { if (!completion) { return; } if (!request) { return; } - + NSURLSessionDataTask *task = [self.session dataTaskWithRequest:request completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) { dispatch_async(dispatch_get_main_queue(), ^{ completion(response, error); }); }]; - + [task resume]; } @@ -365,11 +367,11 @@ - (NSMutableURLRequest *)requestWithURL:(NSURL *)url method:(NSString *)method h { NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:url]; [request setHTTPMethod:method]; - + [headers enumerateKeysAndObjectsUsingBlock:^(NSString *header, NSString *value, BOOL *stop) { [request setValue:value forHTTPHeaderField:header]; }]; - + return [request copy]; } diff --git a/CocoaUPnP/Models/UPPConstants.m b/CocoaUPnP/Models/UPPConstants.m index e4fddfb..3b99f66 100644 --- a/CocoaUPnP/Models/UPPConstants.m +++ b/CocoaUPnP/Models/UPPConstants.m @@ -1,6 +1,8 @@ // CocoaUPnP by A&R Cambridge Ltd, http://www.arcam.co.uk // Copyright 2015 Arcam. See LICENSE file. +@import Foundation; + #import "UPPConstants.h" NSString * const UPPSOAPActionKey = @"SoapAction"; diff --git a/CocoaUPnP/Networking/SSDP/SSDPServiceBrowser.m b/CocoaUPnP/Networking/SSDP/SSDPServiceBrowser.m index 7da8374..d9b1b91 100644 --- a/CocoaUPnP/Networking/SSDP/SSDPServiceBrowser.m +++ b/CocoaUPnP/Networking/SSDP/SSDPServiceBrowser.m @@ -22,9 +22,11 @@ // Expanded for CocoaUPnP by A&R Cambridge Ltd, http://www.arcam.co.uk // Copyright 2015 Arcam. See LICENSE file. +@import UIKit; + #import "SSDPServiceBrowser.h" -#import "GCDAsyncUdpSocket.h" +#import #import "SSDPService.h" #import @@ -54,19 +56,19 @@ @implementation SSDPServiceBrowser #pragma mark - Public Methods - (void)startBrowsingForServiceTypes:(NSString *)serviceType { - + if (self.multicastSocket.isClosed) { [self setupMulticastSocket]; } - + if (self.unicastSocket.isClosed) { [self setupUnicastSocket]; } - + NSString *searchHeader; searchHeader = [self _prepareSearchRequestWithServiceType:serviceType]; NSData *d = [searchHeader dataUsingEncoding:NSUTF8StringEncoding]; - + [self.multicastSocket sendData:d toHost:SSDPMulticastGroupAddress port:SSDPMulticastUDPPort @@ -77,26 +79,26 @@ - (void)startBrowsingForServiceTypes:(NSString *)serviceType { - (void)setupMulticastSocket { [self.multicastSocket setIPv6Enabled:NO]; - + NSError *err = nil; - + NSDictionary *interfaces = [SSDPServiceBrowser availableNetworkInterfaces]; NSData *sourceAddress = _networkInterface? [interfaces objectForKey:_networkInterface] : nil; - + if (!sourceAddress) { sourceAddress = [[interfaces allValues] firstObject]; } - + if (![self.multicastSocket bindToAddress:sourceAddress error:&err]) { [self _notifyDelegateWithError:err]; return; } - + if (![self.multicastSocket joinMulticastGroup:SSDPMulticastGroupAddress error:&err]) { [self _notifyDelegateWithError:err]; return; } - + if (![self.multicastSocket beginReceiving:&err]) { [self _notifyDelegateWithError:err]; return; @@ -106,19 +108,19 @@ - (void)setupMulticastSocket - (void)setupUnicastSocket { [self.unicastSocket setIPv6Enabled:NO]; - + NSError *err = nil; - + if (![self.unicastSocket bindToPort:1900 error:&err]) { [self _notifyDelegateWithError:err]; return; } - + if (![self.unicastSocket joinMulticastGroup:SSDPMulticastGroupAddress error:&err]) { [self _notifyDelegateWithError:err]; return; } - + if (![self.unicastSocket beginReceiving:&err]) { [self _notifyDelegateWithError:err]; return; @@ -139,8 +141,8 @@ - (GCDAsyncUdpSocket *)unicastSocket { if (!_unicastSocket) { _unicastSocket = [[GCDAsyncUdpSocket alloc] - initWithDelegate:self - delegateQueue:dispatch_get_main_queue()]; + initWithDelegate:self + delegateQueue:dispatch_get_main_queue()]; } return _unicastSocket; } @@ -149,7 +151,7 @@ - (void)stopBrowsingForServices { [self closeSocket:self.multicastSocket]; self.multicastSocket = nil; - + [self closeSocket:self.unicastSocket]; self.unicastSocket = nil; } @@ -172,21 +174,21 @@ - (void)udpSocket:(GCDAsyncUdpSocket *)sock didReceiveData:(NSData *)data fromAddress:(NSData *)address withFilterContext:(id)filterContext { NSString *msg = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding]; - + if (!msg) { return; } - + NSDictionary *headers = [self _parseHeadersFromMessage:msg]; SSDPService *service = [[SSDPService alloc] initWithHeaders:headers]; - + if ([headers[SSDPResponseStatusKey] isEqualToString:@"200"]) { [self _notifyDelegateWithFoundService:service]; } - + else if ([headers[SSDPRequestMethodKey] isEqualToString:@"NOTIFY"]) { NSString *nts = headers[@"nts"]; - + if ( [nts isEqualToString:@"ssdp:alive"] ) { [self _notifyDelegateWithFoundService:service]; } @@ -206,10 +208,10 @@ - (NSMutableDictionary *)_parseHeadersFromMessage:(NSString *)message { regularExpressionWithPattern:pattern options:options error:nil]; - + NSMutableDictionary *headers = [NSMutableDictionary dictionary]; __block SSDPMessageType type = SSDPUnknownMessage; - + [message enumerateLinesUsingBlock:^(NSString *line, BOOL *stop) { if (type == SSDPUnknownMessage) { // First line describes type of message @@ -239,7 +241,7 @@ - (NSMutableDictionary *)_parseHeadersFromMessage:(NSString *)message { }]; } }]; - + return headers; } @@ -273,7 +275,7 @@ - (void)_notifyDelegateWithRemovedService:(SSDPService *)service - (NSString *)_prepareSearchRequestWithServiceType:(NSString *)serviceType { NSString *userAgent = [self _userAgentString]; - + return [NSString stringWithFormat: @"M-SEARCH * HTTP/1.1\r\n" "HOST: %@:%d\r\n" @@ -291,20 +293,20 @@ - (NSString *)_userAgentString { NSString *userAgent = nil; NSDictionary *bundleInfos = [[NSBundle mainBundle] infoDictionary]; NSString *bundleExecutable = bundleInfos[(__bridge NSString *)kCFBundleExecutableKey] ?: bundleInfos[(__bridge NSString *)kCFBundleIdentifierKey]; - + #if defined(__IPHONE_OS_VERSION_MIN_REQUIRED) userAgent = [NSString stringWithFormat:@"%@/%@ (%@; iOS %@) %@", bundleExecutable, (__bridge id)CFBundleGetValueForInfoDictionaryKey(CFBundleGetMainBundle(), kCFBundleVersionKey) ?: bundleInfos[(__bridge NSString *)kCFBundleVersionKey], [[UIDevice currentDevice] model], [[UIDevice currentDevice] systemVersion], SSDPVersionString]; - + #elif defined(__MAC_OS_X_VERSION_MIN_REQUIRED) userAgent = [NSString stringWithFormat:@"%@/%@ (Mac OS X %@) %@", bundleExecutable, bundleInfos[@"CFBundleShortVersionString"] ?: bundleInfos[(__bridge NSString *)kCFBundleVersionKey], [[NSProcessInfo processInfo] operatingSystemVersionString], SSDPVersionString]; #endif - + return userAgent; } @@ -312,7 +314,7 @@ + (NSDictionary *)availableNetworkInterfaces { NSMutableDictionary *addresses = [NSMutableDictionary dictionary]; struct ifaddrs *interfaces = NULL; struct ifaddrs *ifa = NULL; - + // retrieve the current interfaces - returns 0 on success if( getifaddrs(&interfaces) == 0 ) { for( ifa = interfaces; ifa != NULL; ifa = ifa->ifa_next ) { @@ -322,10 +324,10 @@ + (NSDictionary *)availableNetworkInterfaces { [addresses setObject:data forKey:if_name]; } } - + freeifaddrs(interfaces); } - + return addresses; } diff --git a/CocoaUPnP/Parsers/UPPDeviceParser.m b/CocoaUPnP/Parsers/UPPDeviceParser.m index 320f405..a83b255 100644 --- a/CocoaUPnP/Parsers/UPPDeviceParser.m +++ b/CocoaUPnP/Parsers/UPPDeviceParser.m @@ -1,13 +1,14 @@ // CocoaUPnP by A&R Cambridge Ltd, http://www.arcam.co.uk // Copyright 2015 Arcam. See LICENSE file. +#import +#import + #import "UPPDeviceParser.h" #import "UPPBasicDevice.h" -#import "Ono.h" #import "UPPDeviceIcon.h" #import "UPPServiceDescription.h" #import "UPPError.h" -#import "AFHTTPSessionManager.h" #import "UPPRequestSerializer.h" #import "UPPMediaRendererDevice.h" #import "UPPMediaServerDevice.h" @@ -17,7 +18,7 @@ @implementation UPPDeviceParser + (void)parseURL:(NSURL *)url withCompletion:(CompletionBlock)completion { if (!completion) { return; } - + AFHTTPSessionManager *manager = [AFHTTPSessionManager manager]; manager.responseSerializer = [AFHTTPResponseSerializer serializer]; [manager GET:url.absoluteString parameters:nil progress:nil success:^(NSURLSessionDataTask * _Nonnull task, NSData *data) { @@ -35,27 +36,27 @@ + (void)parseURL:(NSURL *)url withCompletion:(CompletionBlock)completion - (void)parseWithBaseURL:(NSURL *)baseURL completion:(CompletionBlock)completion { if (!completion) { return; } - + if (self.data.length == 0) { completion(nil, UPPErrorWithCode(UPPErrorCodeEmptyData)); return; } - + NSError *error = nil; ONOXMLDocument *document = [ONOXMLDocument XMLDocumentWithData:self.data error:&error]; - + if (!document) { completion(nil, error); return; } - + __block NSMutableArray *devices; - + [document.rootElement enumerateElementsWithXPath:@"//*[name()='device']" usingBlock:^(ONOXMLElement *element, NSUInteger idx, BOOL *stop) { NSString *deviceType = [[element firstChildWithTag:@"deviceType"] stringValue]; - + UPPBasicDevice *device; - + if ([deviceType rangeOfString:@":MediaRenderer:"].location != NSNotFound) { device = [UPPMediaRendererDevice mediaRendererWithURN:deviceType baseURL:baseURL]; @@ -66,23 +67,23 @@ - (void)parseWithBaseURL:(NSURL *)baseURL completion:(CompletionBlock)completion [self parseElement:element intoDevice:device]; [self parseIcons:[element firstChildWithTag:@"iconList"] intoDevice:device]; [self parseServices:[element firstChildWithTag:@"serviceList"] intoDevice:device]; - + if (!device) { return; } - + if (!devices) { devices = [NSMutableArray array]; } - + [devices addObject:device]; }]; - + if (!devices) { completion(nil, UPPErrorWithCode(UPPErrorCodeNoDeviceElementFound)); return; } - + completion([devices copy], nil); } @@ -95,7 +96,7 @@ - (void)parseElement:(ONOXMLElement *)element intoDevice:(UPPBasicDevice *)devic device.modelNumber = [[element firstChildWithTag:@"modelNumber"] stringValue]; device.serialNumber = [[element firstChildWithTag:@"serialNumber"] stringValue]; device.udn = [[element firstChildWithTag:@"UDN"] stringValue]; - + NSString *url = [[element firstChildWithTag:@"manufacturerURL"] stringValue]; device.manufacturerURL = [NSURL URLWithString:url]; url = [[element firstChildWithTag:@"modelURL"] stringValue]; @@ -114,7 +115,7 @@ - (void)parseIcons:(ONOXMLElement *)iconList intoDevice:(UPPBasicDevice *)device icon.url = [[iconElement firstChildWithTag:@"url"] stringValue]; [icons addObject:icon]; }]; - + if (icons.count > 0) { device.iconList = [icons copy]; } @@ -132,7 +133,7 @@ - (void)parseServices:(ONOXMLElement *)serviceList intoDevice:(UPPBasicDevice *) service.eventSubURL = [[serviceElement firstChildWithTag:@"eventSubURL"] stringValue]; [services addObject:service]; }]; - + if (services.count > 0) { device.services = [services copy]; } diff --git a/CocoaUPnP/Parsers/UPPErrorParser.m b/CocoaUPnP/Parsers/UPPErrorParser.m index 92e244e..bd03c19 100644 --- a/CocoaUPnP/Parsers/UPPErrorParser.m +++ b/CocoaUPnP/Parsers/UPPErrorParser.m @@ -3,7 +3,7 @@ #import "UPPErrorParser.h" #import "UPPError.h" -#import "Ono.h" +#import @implementation UPPErrorParser @@ -12,20 +12,20 @@ + (NSError *)parseErrorXML:(NSData *)data if (!data) { return nil; } - + NSError *error; ONOXMLDocument *document = [ONOXMLDocument XMLDocumentWithData:data error:&error]; - + if (!document) { return error; } - + ONOXMLElement *element = [document firstChildWithXPath:@"//*[name()='UPnPError']"]; NSString *errorCode = [[element firstChildWithTag:@"errorCode"] stringValue]; NSString *errorDescription = [[element firstChildWithTag:@"errorDescription"] stringValue]; NSString *description = [NSString stringWithFormat:@"%@ - %@", errorCode, errorDescription]; - + NSDictionary *userInfo = @{ NSLocalizedDescriptionKey : description }; error = [[NSError alloc] initWithDomain:UPPErrorDomain code:UPPErrorCodeUPnPErrorReturned diff --git a/CocoaUPnP/Parsers/UPPLastChangeParser.m b/CocoaUPnP/Parsers/UPPLastChangeParser.m index b73f186..12f3c87 100644 --- a/CocoaUPnP/Parsers/UPPLastChangeParser.m +++ b/CocoaUPnP/Parsers/UPPLastChangeParser.m @@ -2,7 +2,7 @@ // Copyright 2015 Arcam. See LICENSE file. #import "UPPLastChangeParser.h" -#import "Ono.h" +#import #import "UPPError.h" #import "UPPMediaItemParser.h" diff --git a/CocoaUPnP/Parsers/UPPMediaItemParser.m b/CocoaUPnP/Parsers/UPPMediaItemParser.m index c698f4b..5dd234c 100644 --- a/CocoaUPnP/Parsers/UPPMediaItemParser.m +++ b/CocoaUPnP/Parsers/UPPMediaItemParser.m @@ -2,7 +2,7 @@ // Copyright 2015 Arcam. See LICENSE file. #import "UPPMediaItemParser.h" -#import "Ono.h" +#import #import "UPPMediaItem.h" #import "UPPMediaItemResource.h" #import "UPPError.h" @@ -14,24 +14,24 @@ @implementation UPPMediaItemParser + (void)parseResults:(NSDictionary *)results withCompletion:(void (^)(NSDictionary *results, NSError *error))completion { if (!results || !completion) { return; } - + NSString *resultsString = results[UPnPXMLResultsKey]; - + if (!resultsString) { completion(nil, UPPErrorWithCode(UPPErrorCodeEmptyData)); return; } - + NSError *error = nil; ONOXMLDocument *document = [ONOXMLDocument XMLDocumentWithString:resultsString encoding:NSUTF8StringEncoding error:&error]; - + if (!document) { completion(nil, error); return; } - + NSArray *items = [self parseItemsInDocument:document]; if (items) { NSMutableDictionary *parsedResults = [results mutableCopy]; @@ -46,14 +46,14 @@ + (NSArray *)parseItemsInDocument:(ONOXMLDocument *)document { __block NSMutableArray *items; [document enumerateElementsWithXPath:@"/*[local-name() = 'DIDL-Lite']/*" usingBlock:^(ONOXMLElement *element, NSUInteger idx, BOOL *stop) { - + UPPMediaItem *item = [[UPPMediaItem alloc] init]; - + if ([[element tag] isEqualToString:@"container"]) { item.isContainer = YES; item.childCount = [element valueForAttribute:@"childCount"]; } - + item.albumTitle = [[element firstChildWithTag:@"album"] stringValue]; item.artist = [[element firstChildWithTag:@"artist"] stringValue]; item.date = [[element firstChildWithTag:@"date"] stringValue]; @@ -65,7 +65,7 @@ + (NSArray *)parseItemsInDocument:(ONOXMLDocument *)document item.parentID = [element valueForAttribute:@"parentID"]; item.objectID = [element valueForAttribute:@"id"]; item.resources = [self parseResources:[element childrenWithTag:@"res"]]; - + NSArray *durations = [item.resources valueForKey:@"duration"]; [durations enumerateObjectsUsingBlock:^(NSString *duration, NSUInteger idx, BOOL *stop) { if (duration && ![duration isEqual:[NSNull null]]) { @@ -73,21 +73,21 @@ + (NSArray *)parseItemsInDocument:(ONOXMLDocument *)document *stop = YES; } }]; - + if (!items) { items = [NSMutableArray array]; } - + [items addObject:item]; }]; - + return [items copy]; } + (NSArray *)parseResources:(NSArray *)res { __block NSMutableArray *mutableResources; - + [res enumerateObjectsUsingBlock:^(ONOXMLElement *resource, NSUInteger idx, BOOL *stop) { UPPMediaItemResource *r = [[UPPMediaItemResource alloc] init]; r.numberOfAudioChannels = [resource valueForAttribute:@"nrAudioChannels"]; @@ -97,14 +97,14 @@ + (NSArray *)parseResources:(NSArray *)res r.protocolInfo = [resource valueForAttribute:@"protocolInfo"]; r.itemSize = [resource valueForAttribute:@"size"]; r.resourceURLString = [resource stringValue]; - + if (!mutableResources) { mutableResources = [NSMutableArray array]; } - + [mutableResources addObject:r]; }]; - + return [mutableResources copy]; } @@ -113,22 +113,22 @@ + (NSArray *)parseResources:(NSArray *)res + (NSInteger)durationFromString:(NSString *)string { NSInteger seconds = 0; - + NSArray *components = [string componentsSeparatedByString:@":"]; - + if ([components count] == 3) { // hh NSInteger hours = [(NSString *)components[0] integerValue]; seconds += hours * 60 * 60; - + // mm NSInteger minutes = [(NSString *)components[1] integerValue]; seconds += minutes * 60; - + // ss - actually a double seconds += [(NSString *)components[2] integerValue]; } - + return seconds; } diff --git a/CocoaUPnP/Parsers/UPPResponseParser.m b/CocoaUPnP/Parsers/UPPResponseParser.m index 5a521a3..5f4d316 100644 --- a/CocoaUPnP/Parsers/UPPResponseParser.m +++ b/CocoaUPnP/Parsers/UPPResponseParser.m @@ -2,7 +2,7 @@ // Copyright 2015 Arcam. See LICENSE file. #import "UPPResponseParser.h" -#import "Ono.h" +#import #import "UPPError.h" #import "UPPMediaItemParser.h" @@ -13,37 +13,37 @@ - (void)parseWithResponse:(Response)responseBlock if (!responseBlock) { return; } - + NSError *error = nil; - + if (![self data]) { responseBlock(nil, UPPErrorWithCode(UPPErrorCodeEmptyData)); return; } - + ONOXMLDocument *document = [ONOXMLDocument XMLDocumentWithData:self.data error:&error]; - + if (!document) { responseBlock(nil, error); return; } - + __block NSMutableDictionary *responseDictionary; - + [document enumerateElementsWithXPath:@"/*[local-name() = 'Envelope']/*[local-name() = 'Body']/*/*" usingBlock:^(ONOXMLElement *element, NSUInteger idx, BOOL *stop) { - + if (!responseDictionary) { responseDictionary = [NSMutableDictionary dictionary]; } - + NSString *tag = element.tag; NSString *value = [element stringValue]; - + if (tag && value) { if ([tag rangeOfString:@"MetaData"].location != NSNotFound) { ONOXMLDocument *metadata = [ONOXMLDocument XMLDocumentWithString:value encoding:NSUTF8StringEncoding error:nil]; NSArray *items = [UPPMediaItemParser parseItemsInDocument:metadata]; - + if (items.count > 0) { responseDictionary[tag] = [items firstObject]; } @@ -51,9 +51,9 @@ - (void)parseWithResponse:(Response)responseBlock responseDictionary[tag] = value; } } - + }]; - + responseBlock(responseDictionary, nil); } From b46d7188144527991fbaaed31629c8683034e033 Mon Sep 17 00:00:00 2001 From: Derek Clarkson Date: Thu, 9 Jun 2016 21:38:46 +1000 Subject: [PATCH 3/7] Untracking .DS_Store --- .DS_Store | Bin 6148 -> 0 bytes .gitignore | 1 + 2 files changed, 1 insertion(+) delete mode 100644 .DS_Store diff --git a/.DS_Store b/.DS_Store deleted file mode 100644 index 58d20a5574c61bf9c8e901ced0a0004ad04b2ea2..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6148 zcmeHKy-EZz5T4O17Hkf#vCI<)SKEYhuNMw`Wmgn&-R1DW!XoeJtM~wZ^P}A27Keq1 z%)rc-%w&@62b*Mwh*!IINi-*-3M$Cbm=JMKhK_vj49Ggi4PDVCJweYVCi;sm+53Vn zsHX;Pv+L`+-90x%Z?D^T%|CF>u5W*sIo$8> zHtV8cf`MQl7zhS}0Wg3&TckQM3>ypt1Hr%-19Cnjs9<(1hI(|sXbAw6XS531QcFlq za?Fm!5D^GlD$r8dOANMj_>+&zj>XW@iM{w>U-`3mVO<^bCml|l4Z{Wl!N8b-W9!c4 z{$JylnJn_hDbWiCf`Na=0MF`8y~0QN-TLkG Date: Thu, 9 Jun 2016 23:22:44 +1000 Subject: [PATCH 4/7] Removing empty lines of whitespace I put in. --- CocoaUPnP.xcodeproj/project.pbxproj | 4 +- CocoaUPnP/Events/UPPEventServer.m | 10 +-- .../Events/UPPEventSubscriptionManager.m | 78 +++++++++---------- .../Networking/SSDP/SSDPServiceBrowser.m | 58 +++++++------- CocoaUPnP/Parsers/UPPDeviceParser.m | 32 ++++---- CocoaUPnP/Parsers/UPPErrorParser.m | 8 +- CocoaUPnP/Parsers/UPPLastChangeParser.m | 2 +- CocoaUPnP/Parsers/UPPMediaItemParser.m | 42 +++++----- CocoaUPnP/Parsers/UPPResponseParser.m | 14 ++-- 9 files changed, 124 insertions(+), 124 deletions(-) diff --git a/CocoaUPnP.xcodeproj/project.pbxproj b/CocoaUPnP.xcodeproj/project.pbxproj index 5de9e0a..a3f3662 100644 --- a/CocoaUPnP.xcodeproj/project.pbxproj +++ b/CocoaUPnP.xcodeproj/project.pbxproj @@ -87,7 +87,7 @@ 6C3EE7C71D06EE1400506613 /* UPPEventSubscription.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPEventSubscription.h; sourceTree = ""; }; 6C3EE7C81D06EE1400506613 /* UPPEventSubscription.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPEventSubscription.m; sourceTree = ""; }; 6C3EE7C91D06EE1400506613 /* UPPEventSubscriptionManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPEventSubscriptionManager.h; sourceTree = ""; }; - 6C3EE7CA1D06EE1400506613 /* UPPEventSubscriptionManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPEventSubscriptionManager.m; sourceTree = ""; }; + 6C3EE7CA1D06EE1400506613 /* UPPEventSubscriptionManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; lineEnding = 0; path = UPPEventSubscriptionManager.m; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.objc; }; 6C3EE7CC1D06EE1400506613 /* NSArray+firstObjectMatchingPredicate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSArray+firstObjectMatchingPredicate.h"; sourceTree = ""; }; 6C3EE7CD1D06EE1400506613 /* NSArray+firstObjectMatchingPredicate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSArray+firstObjectMatchingPredicate.m"; sourceTree = ""; }; 6C3EE7CE1D06EE1400506613 /* NSMutableString+xmlNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSMutableString+xmlNode.h"; sourceTree = ""; }; @@ -117,7 +117,7 @@ 6C3EE7E91D06EE1400506613 /* SSDPService.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSDPService.h; sourceTree = ""; }; 6C3EE7EA1D06EE1400506613 /* SSDPService.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSDPService.m; sourceTree = ""; }; 6C3EE7EB1D06EE1400506613 /* SSDPServiceBrowser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSDPServiceBrowser.h; sourceTree = ""; }; - 6C3EE7EC1D06EE1400506613 /* SSDPServiceBrowser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSDPServiceBrowser.m; sourceTree = ""; }; + 6C3EE7EC1D06EE1400506613 /* SSDPServiceBrowser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; lineEnding = 0; path = SSDPServiceBrowser.m; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.objc; }; 6C3EE7ED1D06EE1400506613 /* UPPDiscovery.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPDiscovery.h; sourceTree = ""; }; 6C3EE7EE1D06EE1400506613 /* UPPDiscovery.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UPPDiscovery.m; sourceTree = ""; }; 6C3EE7EF1D06EE1400506613 /* UPPRequestSerializer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UPPRequestSerializer.h; sourceTree = ""; }; diff --git a/CocoaUPnP/Events/UPPEventServer.m b/CocoaUPnP/Events/UPPEventServer.m index 1351080..05ac75e 100644 --- a/CocoaUPnP/Events/UPPEventServer.m +++ b/CocoaUPnP/Events/UPPEventServer.m @@ -18,14 +18,14 @@ @implementation UPPEventServer - (void)startServer { __weak typeof(self) weakSelf = self; - + [self.webServer addHandlerForMethod:@"NOTIFY" path:@"/Event" requestClass:[GCDWebServerDataRequest class] processBlock:^GCDWebServerResponse *(GCDWebServerRequest *request) { if (request != nil) { [weakSelf requestRecieved:(GCDWebServerDataRequest *)request]; } return [[GCDWebServerResponse alloc] init]; }]; - + if ([self.webServer startWithPort:UPPEventServerPort bonjourName:nil]) { NSURL *baseURL = self.webServer.serverURL; self.callbackURL = [baseURL URLByAppendingPathComponent:@"Event"]; @@ -65,18 +65,18 @@ - (void)requestRecieved:(GCDWebServerDataRequest *)request { NSDictionary *headers = request.headers; NSMutableDictionary *eventDictionary = [NSMutableDictionary dictionary]; - + NSString *sid = headers[@"SID"]; if (sid) { [eventDictionary setObject:sid forKey:UPPEventServerSIDKey]; } - + [UPPLastChangeParser parseData:request.data completion:^(NSDictionary *event, NSError *error) { if (event) { eventDictionary[UPPEventServerBodyKey] = event; } }]; - + [self.eventDelegate eventReceived:[eventDictionary copy]]; } diff --git a/CocoaUPnP/Events/UPPEventSubscriptionManager.m b/CocoaUPnP/Events/UPPEventSubscriptionManager.m index aa2f96a..8ee9c91 100644 --- a/CocoaUPnP/Events/UPPEventSubscriptionManager.m +++ b/CocoaUPnP/Events/UPPEventSubscriptionManager.m @@ -19,13 +19,13 @@ @implementation UPPEventSubscriptionManager + (instancetype)sharedManager { static dispatch_once_t onceToken = 0; - + __strong static id _sharedManager = nil; dispatch_once(&onceToken, ^{ NSURLSession *session = [NSURLSession sharedSession]; _sharedManager = [[self alloc] initWithSession:session]; }); - + return _sharedManager; } @@ -35,7 +35,7 @@ - (instancetype)initWithSession:(NSURLSession *)session self.session = session; [self addNotificationObservers]; } - + return self; } @@ -47,12 +47,12 @@ - (void)dealloc - (void)addNotificationObservers { NSNotificationCenter *nc = [NSNotificationCenter defaultCenter]; - + [nc addObserver:self selector:@selector(invalidateAllTimers) name:UIApplicationDidEnterBackgroundNotification object:nil]; - + [nc addObserver:self selector:@selector(renewAllTimers) name:UIApplicationDidBecomeActiveNotification @@ -66,7 +66,7 @@ - (NSMutableArray *)activeSubscriptions if (!_activeSubscriptions) { _activeSubscriptions = [NSMutableArray array]; } - + return _activeSubscriptions; } @@ -75,7 +75,7 @@ - (UPPEventServer *)eventServer if (!_eventServer) { _eventServer = [[UPPEventServer alloc] init]; } - + return _eventServer; } @@ -87,7 +87,7 @@ - (void)subscribeObserver:(id)observer toService:( self.eventServer.eventDelegate = self; [self.eventServer startServer]; } - + // If we already have an existing subscription, add the new observer then // bail out early. UPPEventSubscription *subscription = [self subscriptionWithURL:service.eventSubscriptionURL]; @@ -98,7 +98,7 @@ - (void)subscribeObserver:(id)observer toService:( } return; } - + // Create a new subscription. NSURL *url = service.eventSubscriptionURL; subscription = [UPPEventSubscription subscriptionWithSubscriptionURL:url @@ -123,10 +123,10 @@ - (void)subscribeObserver:(id)observer toService:( - (void)subscribe:(UPPEventSubscription *)subscription completion:(void(^)(NSString *subscriptionID, NSDate *expiryDate, NSError *error))completion { if (!completion) { return; } - + NSURL *url = subscription.eventSubscriptionURL; NSURLRequest *request = [self subscriptionRequestWithEventSubscriptionURL:url]; - + [self sendSubscriptionRequest:request completion:^(NSURLResponse *response, NSError *error) { NSInteger code = [(NSHTTPURLResponse *)response statusCode]; @@ -154,15 +154,15 @@ - (void)renewSubscription:(UPPEventSubscription *)subscription completion:(void( return; } NSURL *subscriptionURL = subscription.eventSubscriptionURL; - + NSDictionary *headers = @{ @"HOST": [subscriptionURL absoluteString], @"SID": [subscription subscriptionID], @"TIMEOUT": @"Second-1800" }; - + NSMutableURLRequest *request = [self requestWithURL:subscriptionURL method:@"SUBSCRIBE" headers:headers]; - + NSURLSessionDataTask *task = [self.session dataTaskWithRequest:request completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) { if (!completion) { return; } @@ -181,7 +181,7 @@ - (void)renewSubscription:(UPPEventSubscription *)subscription completion:(void( completion(subscriptionID, expiryDate, nil); }]; - + [task resume]; } @@ -196,18 +196,18 @@ - (NSURLRequest *)subscriptionRequestWithEventSubscriptionURL:(NSURL *)url NSString *host = [NSString stringWithFormat:@"%@:%@", [subscriptionURL host], [subscriptionURL port]]; - + NSURL *callbackURL = [self.eventServer eventServerCallbackURL]; NSString *callback = [NSString stringWithFormat:@"<%@>", [callbackURL absoluteString]]; - + NSDictionary *headers = @{ @"HOST": host, @"USER-AGENT": @"iOS/8.4 UPnP/1.1 Example/1.0", @"CALLBACK": callback, @"NT": @"upnp:event", @"TIMEOUT": @"Second-1800" }; - - + + return [self requestWithURL:url method:@"SUBSCRIBE" headers:headers]; } @@ -215,21 +215,21 @@ - (void)unsubscribe:(UPPEventSubscription *)subscription completion:(void(^)(BOO { [subscription invalidateTimers]; [self.activeSubscriptions removeObject:subscription]; - + if (!subscription.eventSubscriptionURL || !subscription.subscriptionID) { if (completion) { completion(NO); } return; } - + NSURL *subscriptionURL = subscription.eventSubscriptionURL; - + NSDictionary *headers = @{ @"HOST": [subscriptionURL absoluteString], @"SID": [subscription subscriptionID] }; - + NSMutableURLRequest *request = [self requestWithURL:subscriptionURL method:@"UNSUBSCRIBE" headers:headers]; - + NSURLSessionDataTask *task = [self.session dataTaskWithRequest:request completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) { NSInteger code = [(NSHTTPURLResponse *)response statusCode]; @@ -249,14 +249,14 @@ - (void)unsubscribe:(UPPEventSubscription *)subscription completion:(void(^)(BOO } } }]; - + [task resume]; } - (void)removeObserver:(id)observer fromService:(UPPBasicService *)service completion:(void (^)(BOOL))completion { UPPEventSubscription *subscripton = [self subscriptionWithURL:service.eventSubscriptionURL]; - + if (subscripton) { [subscripton removeEventObserver:observer]; @@ -264,7 +264,7 @@ - (void)removeObserver:(id)observer fromService:(U [self unsubscribe:subscripton completion:nil]; } } - + if (completion) { completion(NO); } @@ -273,18 +273,18 @@ - (void)removeObserver:(id)observer fromService:(U - (void)removeSubscriptionsForServices:(NSArray *)services deviceId:(NSString *)deviceId { NSMutableArray *subscriptions = [NSMutableArray array]; - + for (UPPServiceDescription *service in services) { NSString *identifier = [NSString stringWithFormat:@"%@::%@", deviceId, service.serviceType]; NSArray *objects = [self subscriptionsForServiceIdentifier:identifier]; [subscriptions addObjectsFromArray:objects]; } - + if (subscriptions.count == 0) { return; } - + for (UPPEventSubscription *subscription in subscriptions) { [subscription invalidateTimers]; [self.activeSubscriptions removeObject:subscription]; @@ -299,11 +299,11 @@ - (void)eventReceived:(NSDictionary *)event NSPredicate *predicate = [NSPredicate predicateWithFormat:@"subscriptionID == %@", sid]; UPPEventSubscription *subscription = [self.activeSubscriptions upp_firstObjectMatchingPredicate:predicate]; - + if (!subscription) { return; } - + [subscription informObserversOfEvent:event]; } @@ -327,7 +327,7 @@ - (UPPEventSubscription *)subscriptionWithURL:(NSURL *)url { NSPredicate *predicate = [NSPredicate predicateWithFormat:@"eventSubscriptionURL = %@", url]; NSArray *matches = [self.activeSubscriptions filteredArrayUsingPredicate:predicate]; - + return [matches firstObject]; } @@ -342,10 +342,10 @@ - (NSDate *)dateFromHeader:(NSString *)header if (!header) { return nil; } - + NSString *timeout = [header stringByReplacingOccurrencesOfString:@"Second-" withString:@""]; - + return [NSDate dateWithTimeIntervalSinceNow:[timeout doubleValue]]; } @@ -353,13 +353,13 @@ - (void)sendSubscriptionRequest:(NSURLRequest *)request completion:(void (^)(NSU { if (!completion) { return; } if (!request) { return; } - + NSURLSessionDataTask *task = [self.session dataTaskWithRequest:request completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) { dispatch_async(dispatch_get_main_queue(), ^{ completion(response, error); }); }]; - + [task resume]; } @@ -367,11 +367,11 @@ - (NSMutableURLRequest *)requestWithURL:(NSURL *)url method:(NSString *)method h { NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:url]; [request setHTTPMethod:method]; - + [headers enumerateKeysAndObjectsUsingBlock:^(NSString *header, NSString *value, BOOL *stop) { [request setValue:value forHTTPHeaderField:header]; }]; - + return [request copy]; } diff --git a/CocoaUPnP/Networking/SSDP/SSDPServiceBrowser.m b/CocoaUPnP/Networking/SSDP/SSDPServiceBrowser.m index d9b1b91..137c2db 100644 --- a/CocoaUPnP/Networking/SSDP/SSDPServiceBrowser.m +++ b/CocoaUPnP/Networking/SSDP/SSDPServiceBrowser.m @@ -56,19 +56,19 @@ @implementation SSDPServiceBrowser #pragma mark - Public Methods - (void)startBrowsingForServiceTypes:(NSString *)serviceType { - + if (self.multicastSocket.isClosed) { [self setupMulticastSocket]; } - + if (self.unicastSocket.isClosed) { [self setupUnicastSocket]; } - + NSString *searchHeader; searchHeader = [self _prepareSearchRequestWithServiceType:serviceType]; NSData *d = [searchHeader dataUsingEncoding:NSUTF8StringEncoding]; - + [self.multicastSocket sendData:d toHost:SSDPMulticastGroupAddress port:SSDPMulticastUDPPort @@ -79,26 +79,26 @@ - (void)startBrowsingForServiceTypes:(NSString *)serviceType { - (void)setupMulticastSocket { [self.multicastSocket setIPv6Enabled:NO]; - + NSError *err = nil; - + NSDictionary *interfaces = [SSDPServiceBrowser availableNetworkInterfaces]; NSData *sourceAddress = _networkInterface? [interfaces objectForKey:_networkInterface] : nil; - + if (!sourceAddress) { sourceAddress = [[interfaces allValues] firstObject]; } - + if (![self.multicastSocket bindToAddress:sourceAddress error:&err]) { [self _notifyDelegateWithError:err]; return; } - + if (![self.multicastSocket joinMulticastGroup:SSDPMulticastGroupAddress error:&err]) { [self _notifyDelegateWithError:err]; return; } - + if (![self.multicastSocket beginReceiving:&err]) { [self _notifyDelegateWithError:err]; return; @@ -108,19 +108,19 @@ - (void)setupMulticastSocket - (void)setupUnicastSocket { [self.unicastSocket setIPv6Enabled:NO]; - + NSError *err = nil; - + if (![self.unicastSocket bindToPort:1900 error:&err]) { [self _notifyDelegateWithError:err]; return; } - + if (![self.unicastSocket joinMulticastGroup:SSDPMulticastGroupAddress error:&err]) { [self _notifyDelegateWithError:err]; return; } - + if (![self.unicastSocket beginReceiving:&err]) { [self _notifyDelegateWithError:err]; return; @@ -151,7 +151,7 @@ - (void)stopBrowsingForServices { [self closeSocket:self.multicastSocket]; self.multicastSocket = nil; - + [self closeSocket:self.unicastSocket]; self.unicastSocket = nil; } @@ -174,21 +174,21 @@ - (void)udpSocket:(GCDAsyncUdpSocket *)sock didReceiveData:(NSData *)data fromAddress:(NSData *)address withFilterContext:(id)filterContext { NSString *msg = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding]; - + if (!msg) { return; } - + NSDictionary *headers = [self _parseHeadersFromMessage:msg]; SSDPService *service = [[SSDPService alloc] initWithHeaders:headers]; - + if ([headers[SSDPResponseStatusKey] isEqualToString:@"200"]) { [self _notifyDelegateWithFoundService:service]; } - + else if ([headers[SSDPRequestMethodKey] isEqualToString:@"NOTIFY"]) { NSString *nts = headers[@"nts"]; - + if ( [nts isEqualToString:@"ssdp:alive"] ) { [self _notifyDelegateWithFoundService:service]; } @@ -208,10 +208,10 @@ - (NSMutableDictionary *)_parseHeadersFromMessage:(NSString *)message { regularExpressionWithPattern:pattern options:options error:nil]; - + NSMutableDictionary *headers = [NSMutableDictionary dictionary]; __block SSDPMessageType type = SSDPUnknownMessage; - + [message enumerateLinesUsingBlock:^(NSString *line, BOOL *stop) { if (type == SSDPUnknownMessage) { // First line describes type of message @@ -241,7 +241,7 @@ - (NSMutableDictionary *)_parseHeadersFromMessage:(NSString *)message { }]; } }]; - + return headers; } @@ -275,7 +275,7 @@ - (void)_notifyDelegateWithRemovedService:(SSDPService *)service - (NSString *)_prepareSearchRequestWithServiceType:(NSString *)serviceType { NSString *userAgent = [self _userAgentString]; - + return [NSString stringWithFormat: @"M-SEARCH * HTTP/1.1\r\n" "HOST: %@:%d\r\n" @@ -293,20 +293,20 @@ - (NSString *)_userAgentString { NSString *userAgent = nil; NSDictionary *bundleInfos = [[NSBundle mainBundle] infoDictionary]; NSString *bundleExecutable = bundleInfos[(__bridge NSString *)kCFBundleExecutableKey] ?: bundleInfos[(__bridge NSString *)kCFBundleIdentifierKey]; - + #if defined(__IPHONE_OS_VERSION_MIN_REQUIRED) userAgent = [NSString stringWithFormat:@"%@/%@ (%@; iOS %@) %@", bundleExecutable, (__bridge id)CFBundleGetValueForInfoDictionaryKey(CFBundleGetMainBundle(), kCFBundleVersionKey) ?: bundleInfos[(__bridge NSString *)kCFBundleVersionKey], [[UIDevice currentDevice] model], [[UIDevice currentDevice] systemVersion], SSDPVersionString]; - + #elif defined(__MAC_OS_X_VERSION_MIN_REQUIRED) userAgent = [NSString stringWithFormat:@"%@/%@ (Mac OS X %@) %@", bundleExecutable, bundleInfos[@"CFBundleShortVersionString"] ?: bundleInfos[(__bridge NSString *)kCFBundleVersionKey], [[NSProcessInfo processInfo] operatingSystemVersionString], SSDPVersionString]; #endif - + return userAgent; } @@ -314,7 +314,7 @@ + (NSDictionary *)availableNetworkInterfaces { NSMutableDictionary *addresses = [NSMutableDictionary dictionary]; struct ifaddrs *interfaces = NULL; struct ifaddrs *ifa = NULL; - + // retrieve the current interfaces - returns 0 on success if( getifaddrs(&interfaces) == 0 ) { for( ifa = interfaces; ifa != NULL; ifa = ifa->ifa_next ) { @@ -327,7 +327,7 @@ + (NSDictionary *)availableNetworkInterfaces { freeifaddrs(interfaces); } - + return addresses; } diff --git a/CocoaUPnP/Parsers/UPPDeviceParser.m b/CocoaUPnP/Parsers/UPPDeviceParser.m index a83b255..ffc5b35 100644 --- a/CocoaUPnP/Parsers/UPPDeviceParser.m +++ b/CocoaUPnP/Parsers/UPPDeviceParser.m @@ -18,7 +18,7 @@ @implementation UPPDeviceParser + (void)parseURL:(NSURL *)url withCompletion:(CompletionBlock)completion { if (!completion) { return; } - + AFHTTPSessionManager *manager = [AFHTTPSessionManager manager]; manager.responseSerializer = [AFHTTPResponseSerializer serializer]; [manager GET:url.absoluteString parameters:nil progress:nil success:^(NSURLSessionDataTask * _Nonnull task, NSData *data) { @@ -36,27 +36,27 @@ + (void)parseURL:(NSURL *)url withCompletion:(CompletionBlock)completion - (void)parseWithBaseURL:(NSURL *)baseURL completion:(CompletionBlock)completion { if (!completion) { return; } - + if (self.data.length == 0) { completion(nil, UPPErrorWithCode(UPPErrorCodeEmptyData)); return; } - + NSError *error = nil; ONOXMLDocument *document = [ONOXMLDocument XMLDocumentWithData:self.data error:&error]; - + if (!document) { completion(nil, error); return; } - + __block NSMutableArray *devices; - + [document.rootElement enumerateElementsWithXPath:@"//*[name()='device']" usingBlock:^(ONOXMLElement *element, NSUInteger idx, BOOL *stop) { NSString *deviceType = [[element firstChildWithTag:@"deviceType"] stringValue]; - + UPPBasicDevice *device; - + if ([deviceType rangeOfString:@":MediaRenderer:"].location != NSNotFound) { device = [UPPMediaRendererDevice mediaRendererWithURN:deviceType baseURL:baseURL]; @@ -67,23 +67,23 @@ - (void)parseWithBaseURL:(NSURL *)baseURL completion:(CompletionBlock)completion [self parseElement:element intoDevice:device]; [self parseIcons:[element firstChildWithTag:@"iconList"] intoDevice:device]; [self parseServices:[element firstChildWithTag:@"serviceList"] intoDevice:device]; - + if (!device) { return; } - + if (!devices) { devices = [NSMutableArray array]; } - + [devices addObject:device]; }]; - + if (!devices) { completion(nil, UPPErrorWithCode(UPPErrorCodeNoDeviceElementFound)); return; } - + completion([devices copy], nil); } @@ -96,7 +96,7 @@ - (void)parseElement:(ONOXMLElement *)element intoDevice:(UPPBasicDevice *)devic device.modelNumber = [[element firstChildWithTag:@"modelNumber"] stringValue]; device.serialNumber = [[element firstChildWithTag:@"serialNumber"] stringValue]; device.udn = [[element firstChildWithTag:@"UDN"] stringValue]; - + NSString *url = [[element firstChildWithTag:@"manufacturerURL"] stringValue]; device.manufacturerURL = [NSURL URLWithString:url]; url = [[element firstChildWithTag:@"modelURL"] stringValue]; @@ -115,7 +115,7 @@ - (void)parseIcons:(ONOXMLElement *)iconList intoDevice:(UPPBasicDevice *)device icon.url = [[iconElement firstChildWithTag:@"url"] stringValue]; [icons addObject:icon]; }]; - + if (icons.count > 0) { device.iconList = [icons copy]; } @@ -133,7 +133,7 @@ - (void)parseServices:(ONOXMLElement *)serviceList intoDevice:(UPPBasicDevice *) service.eventSubURL = [[serviceElement firstChildWithTag:@"eventSubURL"] stringValue]; [services addObject:service]; }]; - + if (services.count > 0) { device.services = [services copy]; } diff --git a/CocoaUPnP/Parsers/UPPErrorParser.m b/CocoaUPnP/Parsers/UPPErrorParser.m index bd03c19..dec5be6 100644 --- a/CocoaUPnP/Parsers/UPPErrorParser.m +++ b/CocoaUPnP/Parsers/UPPErrorParser.m @@ -12,20 +12,20 @@ + (NSError *)parseErrorXML:(NSData *)data if (!data) { return nil; } - + NSError *error; ONOXMLDocument *document = [ONOXMLDocument XMLDocumentWithData:data error:&error]; - + if (!document) { return error; } - + ONOXMLElement *element = [document firstChildWithXPath:@"//*[name()='UPnPError']"]; NSString *errorCode = [[element firstChildWithTag:@"errorCode"] stringValue]; NSString *errorDescription = [[element firstChildWithTag:@"errorDescription"] stringValue]; NSString *description = [NSString stringWithFormat:@"%@ - %@", errorCode, errorDescription]; - + NSDictionary *userInfo = @{ NSLocalizedDescriptionKey : description }; error = [[NSError alloc] initWithDomain:UPPErrorDomain code:UPPErrorCodeUPnPErrorReturned diff --git a/CocoaUPnP/Parsers/UPPLastChangeParser.m b/CocoaUPnP/Parsers/UPPLastChangeParser.m index 12f3c87..487a980 100644 --- a/CocoaUPnP/Parsers/UPPLastChangeParser.m +++ b/CocoaUPnP/Parsers/UPPLastChangeParser.m @@ -50,7 +50,7 @@ + (void)parseData:(NSData *)data completion:(void (^)(NSDictionary *event, NSErr if (value.length == 0) { value = [element stringValue]; } - + if (tag && value) { responseDictionary[tag] = value; } diff --git a/CocoaUPnP/Parsers/UPPMediaItemParser.m b/CocoaUPnP/Parsers/UPPMediaItemParser.m index 5dd234c..1e8bbdb 100644 --- a/CocoaUPnP/Parsers/UPPMediaItemParser.m +++ b/CocoaUPnP/Parsers/UPPMediaItemParser.m @@ -14,24 +14,24 @@ @implementation UPPMediaItemParser + (void)parseResults:(NSDictionary *)results withCompletion:(void (^)(NSDictionary *results, NSError *error))completion { if (!results || !completion) { return; } - + NSString *resultsString = results[UPnPXMLResultsKey]; - + if (!resultsString) { completion(nil, UPPErrorWithCode(UPPErrorCodeEmptyData)); return; } - + NSError *error = nil; ONOXMLDocument *document = [ONOXMLDocument XMLDocumentWithString:resultsString encoding:NSUTF8StringEncoding error:&error]; - + if (!document) { completion(nil, error); return; } - + NSArray *items = [self parseItemsInDocument:document]; if (items) { NSMutableDictionary *parsedResults = [results mutableCopy]; @@ -46,14 +46,14 @@ + (NSArray *)parseItemsInDocument:(ONOXMLDocument *)document { __block NSMutableArray *items; [document enumerateElementsWithXPath:@"/*[local-name() = 'DIDL-Lite']/*" usingBlock:^(ONOXMLElement *element, NSUInteger idx, BOOL *stop) { - + UPPMediaItem *item = [[UPPMediaItem alloc] init]; - + if ([[element tag] isEqualToString:@"container"]) { item.isContainer = YES; item.childCount = [element valueForAttribute:@"childCount"]; } - + item.albumTitle = [[element firstChildWithTag:@"album"] stringValue]; item.artist = [[element firstChildWithTag:@"artist"] stringValue]; item.date = [[element firstChildWithTag:@"date"] stringValue]; @@ -65,7 +65,7 @@ + (NSArray *)parseItemsInDocument:(ONOXMLDocument *)document item.parentID = [element valueForAttribute:@"parentID"]; item.objectID = [element valueForAttribute:@"id"]; item.resources = [self parseResources:[element childrenWithTag:@"res"]]; - + NSArray *durations = [item.resources valueForKey:@"duration"]; [durations enumerateObjectsUsingBlock:^(NSString *duration, NSUInteger idx, BOOL *stop) { if (duration && ![duration isEqual:[NSNull null]]) { @@ -73,21 +73,21 @@ + (NSArray *)parseItemsInDocument:(ONOXMLDocument *)document *stop = YES; } }]; - + if (!items) { items = [NSMutableArray array]; } - + [items addObject:item]; }]; - + return [items copy]; } + (NSArray *)parseResources:(NSArray *)res { __block NSMutableArray *mutableResources; - + [res enumerateObjectsUsingBlock:^(ONOXMLElement *resource, NSUInteger idx, BOOL *stop) { UPPMediaItemResource *r = [[UPPMediaItemResource alloc] init]; r.numberOfAudioChannels = [resource valueForAttribute:@"nrAudioChannels"]; @@ -97,14 +97,14 @@ + (NSArray *)parseResources:(NSArray *)res r.protocolInfo = [resource valueForAttribute:@"protocolInfo"]; r.itemSize = [resource valueForAttribute:@"size"]; r.resourceURLString = [resource stringValue]; - + if (!mutableResources) { mutableResources = [NSMutableArray array]; } - + [mutableResources addObject:r]; }]; - + return [mutableResources copy]; } @@ -113,22 +113,22 @@ + (NSArray *)parseResources:(NSArray *)res + (NSInteger)durationFromString:(NSString *)string { NSInteger seconds = 0; - + NSArray *components = [string componentsSeparatedByString:@":"]; - + if ([components count] == 3) { // hh NSInteger hours = [(NSString *)components[0] integerValue]; seconds += hours * 60 * 60; - + // mm NSInteger minutes = [(NSString *)components[1] integerValue]; seconds += minutes * 60; - + // ss - actually a double seconds += [(NSString *)components[2] integerValue]; } - + return seconds; } diff --git a/CocoaUPnP/Parsers/UPPResponseParser.m b/CocoaUPnP/Parsers/UPPResponseParser.m index 5f4d316..3152998 100644 --- a/CocoaUPnP/Parsers/UPPResponseParser.m +++ b/CocoaUPnP/Parsers/UPPResponseParser.m @@ -13,23 +13,23 @@ - (void)parseWithResponse:(Response)responseBlock if (!responseBlock) { return; } - + NSError *error = nil; - + if (![self data]) { responseBlock(nil, UPPErrorWithCode(UPPErrorCodeEmptyData)); return; } - + ONOXMLDocument *document = [ONOXMLDocument XMLDocumentWithData:self.data error:&error]; - + if (!document) { responseBlock(nil, error); return; } - + __block NSMutableDictionary *responseDictionary; - + [document enumerateElementsWithXPath:@"/*[local-name() = 'Envelope']/*[local-name() = 'Body']/*/*" usingBlock:^(ONOXMLElement *element, NSUInteger idx, BOOL *stop) { if (!responseDictionary) { @@ -53,7 +53,7 @@ - (void)parseWithResponse:(Response)responseBlock } }]; - + responseBlock(responseDictionary, nil); } From 17ef2c3d178c6f3d52b96b76b76a2a79b68bd806 Mon Sep 17 00:00:00 2001 From: Derek Clarkson Date: Thu, 9 Jun 2016 23:28:43 +1000 Subject: [PATCH 5/7] Some longer whitespace lines removed. --- .../Events/UPPEventSubscriptionManager.m | 20 +++++++++---------- .../Networking/SSDP/SSDPServiceBrowser.m | 2 +- CocoaUPnP/Parsers/UPPResponseParser.m | 10 +++++----- 3 files changed, 16 insertions(+), 16 deletions(-) diff --git a/CocoaUPnP/Events/UPPEventSubscriptionManager.m b/CocoaUPnP/Events/UPPEventSubscriptionManager.m index 8ee9c91..4cd23fc 100644 --- a/CocoaUPnP/Events/UPPEventSubscriptionManager.m +++ b/CocoaUPnP/Events/UPPEventSubscriptionManager.m @@ -129,7 +129,7 @@ - (void)subscribe:(UPPEventSubscription *)subscription completion:(void(^)(NSStr [self sendSubscriptionRequest:request completion:^(NSURLResponse *response, NSError *error) { NSInteger code = [(NSHTTPURLResponse *)response statusCode]; - + if (code != 200) { if (self.activeSubscriptions.count == 0) { [self.eventServer stopServer]; @@ -164,21 +164,21 @@ - (void)renewSubscription:(UPPEventSubscription *)subscription completion:(void( headers:headers]; NSURLSessionDataTask *task = [self.session dataTaskWithRequest:request completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) { - + if (!completion) { return; } - + NSInteger code = [(NSHTTPURLResponse *)response statusCode]; - + if (code != 200) { NSError *e = error ?: UPPErrorWithCodeAndDescription(code, @"Renew subscription error"); completion(nil, nil, e); return; } - + NSDictionary *headers = [(NSHTTPURLResponse *)response allHeaderFields]; NSString *subscriptionID = headers[@"SID"]; NSDate *expiryDate = [self dateFromHeader:headers[@"TIMEOUT"]]; - + completion(subscriptionID, expiryDate, nil); }]; @@ -231,11 +231,11 @@ - (void)unsubscribe:(UPPEventSubscription *)subscription completion:(void(^)(BOO headers:headers]; NSURLSessionDataTask *task = [self.session dataTaskWithRequest:request completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) { - + NSInteger code = [(NSHTTPURLResponse *)response statusCode]; - + if (code == 200) { - + if (self.activeSubscriptions.count == 0) { [self.eventServer stopServer]; self.eventServer = nil; @@ -259,7 +259,7 @@ - (void)removeObserver:(id)observer fromService:(U if (subscripton) { [subscripton removeEventObserver:observer]; - + if ([subscripton eventObservers].count == 0) { [self unsubscribe:subscripton completion:nil]; } diff --git a/CocoaUPnP/Networking/SSDP/SSDPServiceBrowser.m b/CocoaUPnP/Networking/SSDP/SSDPServiceBrowser.m index 137c2db..8e056c5 100644 --- a/CocoaUPnP/Networking/SSDP/SSDPServiceBrowser.m +++ b/CocoaUPnP/Networking/SSDP/SSDPServiceBrowser.m @@ -324,7 +324,7 @@ + (NSDictionary *)availableNetworkInterfaces { [addresses setObject:data forKey:if_name]; } } - + freeifaddrs(interfaces); } diff --git a/CocoaUPnP/Parsers/UPPResponseParser.m b/CocoaUPnP/Parsers/UPPResponseParser.m index 3152998..e2e49c8 100644 --- a/CocoaUPnP/Parsers/UPPResponseParser.m +++ b/CocoaUPnP/Parsers/UPPResponseParser.m @@ -31,19 +31,19 @@ - (void)parseWithResponse:(Response)responseBlock __block NSMutableDictionary *responseDictionary; [document enumerateElementsWithXPath:@"/*[local-name() = 'Envelope']/*[local-name() = 'Body']/*/*" usingBlock:^(ONOXMLElement *element, NSUInteger idx, BOOL *stop) { - + if (!responseDictionary) { responseDictionary = [NSMutableDictionary dictionary]; } - + NSString *tag = element.tag; NSString *value = [element stringValue]; - + if (tag && value) { if ([tag rangeOfString:@"MetaData"].location != NSNotFound) { ONOXMLDocument *metadata = [ONOXMLDocument XMLDocumentWithString:value encoding:NSUTF8StringEncoding error:nil]; NSArray *items = [UPPMediaItemParser parseItemsInDocument:metadata]; - + if (items.count > 0) { responseDictionary[tag] = [items firstObject]; } @@ -51,7 +51,7 @@ - (void)parseWithResponse:(Response)responseBlock responseDictionary[tag] = value; } } - + }]; responseBlock(responseDictionary, nil); From 6b6e53cb9088ddb99b13fcfc57bc86b352f9bd20 Mon Sep 17 00:00:00 2001 From: Derek Clarkson Date: Thu, 9 Jun 2016 23:37:00 +1000 Subject: [PATCH 6/7] Adding module file to enable usage as a module. I've set one header as private to illustrate how that can work. --- CocoaUPnP.xcodeproj/project.pbxproj | 26 +++++++++++++++++++++----- CocoaUPnP/CocoaUPnP.h | 8 +++++++- module.modulemap | 4 ++++ module.private.modulemap | 4 ++++ 4 files changed, 36 insertions(+), 6 deletions(-) create mode 100644 module.modulemap create mode 100644 module.private.modulemap diff --git a/CocoaUPnP.xcodeproj/project.pbxproj b/CocoaUPnP.xcodeproj/project.pbxproj index a3f3662..71bb603 100644 --- a/CocoaUPnP.xcodeproj/project.pbxproj +++ b/CocoaUPnP.xcodeproj/project.pbxproj @@ -57,7 +57,7 @@ 6C3EE83E1D06EE1400506613 /* UPPDeviceParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7F91D06EE1400506613 /* UPPDeviceParser.m */; }; 6C3EE83F1D06EE1400506613 /* UPPErrorParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7FA1D06EE1400506613 /* UPPErrorParser.h */; settings = {ATTRIBUTES = (Public, ); }; }; 6C3EE8401D06EE1400506613 /* UPPErrorParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7FB1D06EE1400506613 /* UPPErrorParser.m */; }; - 6C3EE8411D06EE1400506613 /* UPPLastChangeParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7FC1D06EE1400506613 /* UPPLastChangeParser.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6C3EE8411D06EE1400506613 /* UPPLastChangeParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7FC1D06EE1400506613 /* UPPLastChangeParser.h */; settings = {ATTRIBUTES = (Private, ); }; }; 6C3EE8421D06EE1400506613 /* UPPLastChangeParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7FD1D06EE1400506613 /* UPPLastChangeParser.m */; }; 6C3EE8431D06EE1400506613 /* UPPMediaItemParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 6C3EE7FE1D06EE1400506613 /* UPPMediaItemParser.h */; settings = {ATTRIBUTES = (Public, ); }; }; 6C3EE8441D06EE1400506613 /* UPPMediaItemParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 6C3EE7FF1D06EE1400506613 /* UPPMediaItemParser.m */; }; @@ -157,6 +157,8 @@ 6CA6C7721D06ED8700BA8CF1 /* CocoaUPnP.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = CocoaUPnP.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 6CA6C7751D06ED8800BA8CF1 /* CocoaUPnP.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CocoaUPnP.h; sourceTree = ""; }; 6CA6C7771D06ED8800BA8CF1 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 6CA741F01D09A76B007CCFEF /* module.modulemap */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = "sourcecode.module-map"; path = module.modulemap; sourceTree = ""; }; + 6CA741F11D09A76B007CCFEF /* module.private.modulemap */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = "sourcecode.module-map"; path = module.private.modulemap; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -301,10 +303,9 @@ 6CA6C7681D06ED8700BA8CF1 = { isa = PBXGroup; children = ( - 6C3EE8681D06F9F400506613 /* AFNetworking.framework */, - 6C3EE8691D06F9F400506613 /* CocoaAsyncSocket.framework */, - 6C3EE86A1D06F9F400506613 /* GCDWebServers.framework */, - 6C3EE86B1D06F9F400506613 /* Ono.framework */, + 6CA741F01D09A76B007CCFEF /* module.modulemap */, + 6CA741F11D09A76B007CCFEF /* module.private.modulemap */, + 6CA741EF1D09A6AF007CCFEF /* New Group */, 6C3EE8521D06EE8100506613 /* Cartfile */, 6CA6C7771D06ED8800BA8CF1 /* Info.plist */, 6CA6C7741D06ED8800BA8CF1 /* CocoaUPnP */, @@ -335,6 +336,17 @@ path = CocoaUPnP; sourceTree = ""; }; + 6CA741EF1D09A6AF007CCFEF /* New Group */ = { + isa = PBXGroup; + children = ( + 6C3EE8681D06F9F400506613 /* AFNetworking.framework */, + 6C3EE8691D06F9F400506613 /* CocoaAsyncSocket.framework */, + 6C3EE86A1D06F9F400506613 /* GCDWebServers.framework */, + 6C3EE86B1D06F9F400506613 /* Ono.framework */, + ); + name = "New Group"; + sourceTree = ""; + }; /* End PBXGroup section */ /* Begin PBXHeadersBuildPhase section */ @@ -590,6 +602,8 @@ INFOPLIST_FILE = "$(SRCROOT)/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + MODULEMAP_FILE = module.modulemap; + MODULEMAP_PRIVATE_FILE = module.private.modulemap; PRODUCT_BUNDLE_IDENTIFIER = uk.com.arcam.cocoaupnp; PRODUCT_NAME = "$(TARGET_NAME)"; SKIP_INSTALL = YES; @@ -610,6 +624,8 @@ INFOPLIST_FILE = "$(SRCROOT)/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + MODULEMAP_FILE = module.modulemap; + MODULEMAP_PRIVATE_FILE = module.private.modulemap; PRODUCT_BUNDLE_IDENTIFIER = uk.com.arcam.cocoaupnp; PRODUCT_NAME = "$(TARGET_NAME)"; SKIP_INSTALL = YES; diff --git a/CocoaUPnP/CocoaUPnP.h b/CocoaUPnP/CocoaUPnP.h index 5cb33d0..3d434e9 100644 --- a/CocoaUPnP/CocoaUPnP.h +++ b/CocoaUPnP/CocoaUPnP.h @@ -3,6 +3,12 @@ #import +//! Project version number for CocoaUPnP. +FOUNDATION_EXPORT double CocoaUPnPVersionNumber; + +//! Project version string for CocoaUPnP. +FOUNDATION_EXPORT const unsigned char CocoaUPnPVersionString[]; + // Events #import "UPPEventServer.h" #import "UPPEventSubscription.h" @@ -35,7 +41,7 @@ #import "UPPBaseParser.h" #import "UPPDeviceParser.h" #import "UPPErrorParser.h" -#import "UPPLastChangeParser.h" +//#import "UPPLastChangeParser.h" #import "UPPMediaItemParser.h" #import "UPPResponseParser.h" diff --git a/module.modulemap b/module.modulemap new file mode 100644 index 0000000..20cddb1 --- /dev/null +++ b/module.modulemap @@ -0,0 +1,4 @@ +module CocoaUPnP { + umbrella header "Headers/CocoaUPnP.h" + requires objc_arc +} \ No newline at end of file diff --git a/module.private.modulemap b/module.private.modulemap new file mode 100644 index 0000000..3707a87 --- /dev/null +++ b/module.private.modulemap @@ -0,0 +1,4 @@ +explicit module CocoaUPnP.Private { + umbrella "PrivateHeaders" + requires objc_arc +} \ No newline at end of file From a56062bcc883faa01976ea13fe57491add448b7d Mon Sep 17 00:00:00 2001 From: Derek Clarkson Date: Mon, 13 Jun 2016 20:44:06 +1000 Subject: [PATCH 7/7] Adding carthage support tag to readme. --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 94b6583..08a9fea 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,6 @@ # CocoaUPnP +[![Carthage compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/Carthage/Carthage) [![Build Status](https://travis-ci.org/arcam/CocoaUPnP.svg)](https://travis-ci.org/arcam/CocoaUPnP) [![Coverage Status](https://coveralls.io/repos/arcam/CocoaUPnP/badge.svg)](https://coveralls.io/r/arcam/CocoaUPnP) [![Pod Version](https://img.shields.io/cocoapods/v/CocoaUPnP.svg)](http://cocoadocs.org/docsets/CocoaUPnP/)