Repository: BalestraPatrick/Stryng Branch: master Commit: 8601b55251de Files: 19 Total size: 75.0 KB Directory structure: gitextract_sjq88rjs/ ├── .circleci/ │ └── config.yml ├── .gitignore ├── .swift-version ├── Configs/ │ ├── Stryng.plist │ └── StryngTests.plist ├── LICENSE ├── Package.swift ├── README.md ├── Sources/ │ └── Stryng.swift ├── Stryng.podspec ├── Stryng.xcodeproj/ │ ├── project.pbxproj │ ├── project.xcworkspace/ │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata/ │ │ └── IDEWorkspaceChecks.plist │ └── xcshareddata/ │ └── xcschemes/ │ ├── Stryng-iOS.xcscheme │ ├── Stryng-macOS.xcscheme │ ├── Stryng-tvOS.xcscheme │ └── Stryng-watchOS.xcscheme └── Tests/ ├── LinuxMain.swift └── StryngTests/ └── StryngTests.swift ================================================ FILE CONTENTS ================================================ ================================================ FILE: .circleci/config.yml ================================================ version: 2 jobs: build: macos: xcode: "10.0.0" steps: - checkout # Build the app and run tests - run: name: Build and run tests command: fastlane scan environment: SCAN_DEVICE: iPhone X SCAN_SCHEME: Stryng-iOS # Collect XML test results data to show in the UI, # and save the same XML files under test-results folder # in the Artifacts tab - store_test_results: path: test_output/report.xml - store_artifacts: path: /tmp/test-results destination: scan-test-results - store_artifacts: path: ~/Library/Logs/scan destination: scan-logs ================================================ FILE: .gitignore ================================================ ## Build generated build/ DerivedData ## Various settings *.pbxuser !default.pbxuser *.mode1v3 !default.mode1v3 *.mode2v3 !default.mode2v3 *.perspectivev3 !default.perspectivev3 xcuserdata ## Other *.xccheckout *.moved-aside *.xcuserstate *.xcscmblueprint ## Obj-C/Swift specific *.hmap *.ipa ================================================ FILE: .swift-version ================================================ 4.2 ================================================ FILE: Configs/Stryng.plist ================================================ 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) NSHumanReadableCopyright Copyright © 2017 Patrick Balestra. All rights reserved. NSPrincipalClass ================================================ FILE: Configs/StryngTests.plist ================================================ CFBundleDevelopmentRegion en CFBundleExecutable $(EXECUTABLE_NAME) CFBundleIdentifier $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundleName $(PRODUCT_NAME) CFBundlePackageType BNDL CFBundleShortVersionString 1.0 CFBundleSignature ???? CFBundleVersion 1 ================================================ FILE: LICENSE ================================================ The MIT License (MIT) Copyright (c) 2017 Patrick Balestra Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ================================================ FILE: Package.swift ================================================ // swift-tools-version:4.0 // The swift-tools-version declares the minimum version of Swift required to build this package. import PackageDescription let package = Package( name: "Stryng", products: [ // Products define the executables and libraries produced by a package, and make them visible to other packages. .library( name: "Stryng", targets: ["Stryng"] ), ], dependencies: [ // Dependencies declare other packages that this package depends on. // .package(url: /* package url */, from: "1.0.0"), ], targets: [ // Targets are the basic building blocks of a package. A target can define a module or a test suite. // Targets can depend on other targets in this package, and on products in packages which this package depends on. .target( name: "Stryng", dependencies: [], path: "Sources" ), .testTarget( name: "StryngTests", dependencies: ["Stryng"], path: "Tests" ), ] ) ================================================ FILE: README.md ================================================

Circle CI Carthage License Platform Twitter: @BalestraPatrick

# Stryng `Stryng` is designed to make it easier to work with strings by using the common and easy to remember subscript syntax and accessing characters and ranges with `Int` indices. Swift's strings management is one of the most painful feature of the language. Sure, it's great to have Unicode correctness and efficiency, but this comes at a cost: too much verbosity and complexity. ## Examples Retrieve a single character at a specific position. ```swift let string = "Example" // With Stryng string[1] // "x" // Without string[string.index(string.startIndex, offsetBy: 1)] // "x" ``` Retrieve the substring up to a specific index. ```swift let string = "Example" // With Stryng string[..<2] // "Ex" // Without string[..] containing all positions of the subtring. ``` Convert a `Substring` to a `String`. ```swift let example = "Example" example[1...5].string // Returns a `String?` instead of a `Substring?` ``` ## Usage This is an up to date list of the supported subscripts. Take a look at [`StryngTests.swift`](https://github.com/BalestraPatrick/Stryng/blob/master/Tests/StryngTests/StryngTests.swift) if you want to see some more real code examples. ```swift // String[1] public subscript(index: Int) -> Character? // String[0..<1] public subscript(range: Range) -> Substring? // String[0...1] public subscript(range: ClosedRange) -> Substring? // String[..<1] public subscript(value: PartialRangeUpTo) -> Substring? // String[...1] public subscript(value: PartialRangeThrough) -> Substring? // String[1...] public subscript(value: PartialRangeFrom) -> Substring? // String["substring"] public subscript(string: String) -> [Range] // String["begin"..."end"] public subscript(range: ClosedRange) -> [ClosedRange] // String["begin"..<"end"] public subscript(range: Range) -> [Range] // String[Character("a")] public subscript(character: Character) -> [String.Index] // String["begin"...] public subscript(range: PartialRangeFrom) -> PartialRangeFrom? // String[..."end"] public subscript(range: PartialRangeThrough) -> PartialRangeThrough? ``` ## Installation ### Cocoapods To install via [Cocoapods](http://cocoapods.org/), add the following line to your Podfile: ```ruby pod 'Stryng' ``` ### Swift Package Manager To install via the [Swift Package Manager](https://swift.org/package-manager/), add the following line to the `dependencies` array in your `Package.swift` file: ```swift .package(url: "https://github.com/BalestraPatrick/Stryng.git", from: "0.4.1") ``` Then, still in your `Package.swift`, add `"Stryng"` to your *target's* `dependencies` array. Finally, in your terminal, run the following command to update your dependencies: ```bash $ swift package update ``` ## Disclosure Yes, string traversal in Swift can be slow. The reason why these subscripts don't exist in the standard library is that some people think that it hides the performance implications of traversing a string. Traversing a string from the `startIndex` until the `endIndex` has complexity O(n). If you need to get a character at a specific index, in one way or another you will have to traverse the string, but why would you need 3 lines of code instead of 1 to do that if you know what you're doing? This is why Stryng is here to help you. ## Contribute We'd love your help. Head over to the [issues](https://github.com/BalestraPatrick/Stryng/issues) with your feedback. Bonus points if you open a [Pull request](https://github.com/BalestraPatrick/Stryng/pulls) with a failing test for a bug or a new feature! ⭐️ ## Author I'm [Patrick Balestra](http://www.patrickbalestra.com). Email: [me@patrickbalestra.com](mailto:me@patrickbalestra.com) Twitter: [@BalestraPatrick](http://twitter.com/BalestraPatrick). ## License `Stryng` is available under the MIT license. See the [LICENSE](LICENSE) file for more info. ================================================ FILE: Sources/Stryng.swift ================================================ // // Stryng.swift // Stryng // // Created by Patrick Balestra on 12/2/17. // Copyright © 2017 Stryng. All rights reserved. // import Foundation public extension String { // String[1] public subscript(index: Int) -> Character? { guard !self.isEmpty, let stringIndex = self.index(startIndex, offsetBy: index, limitedBy: self.index(before: endIndex)) else { return nil } return self[stringIndex] } // String[0..<1] public subscript(range: Range) -> Substring? { guard let left = indexOffset(by: range.lowerBound) else { return nil } guard let right = index(left, offsetBy: range.upperBound - range.lowerBound, limitedBy: endIndex) else { return nil } return self[left..) -> Substring? { if range.upperBound < 0 { guard abs(range.lowerBound) <= count else { return nil } return self[(count - abs(range.lowerBound))...] } guard let left = indexOffset(by: range.lowerBound) else { return nil } guard let right = index(left, offsetBy: range.upperBound - range.lowerBound, limitedBy: endIndex) else { return nil } return self[left...right] } // String[..<1] public subscript(value: PartialRangeUpTo) -> Substring? { if value.upperBound < 0 { guard abs(value.upperBound) <= count else { return nil } return self[..<(count - abs(value.upperBound))] } guard let right = indexOffset(by: value.upperBound) else { return nil } return self[..) -> Substring? { guard let right = self.indexOffset(by: value.upperBound) else { return nil } return self[...right] } // String[1...] public subscript(value: PartialRangeFrom) -> Substring? { guard let left = self.indexOffset(by: value.lowerBound) else { return nil } return self[left...] } // String["substring"] public subscript(string: String) -> [Range] { var occurences = [Range]() var initialLeftBound = startIndex while initialLeftBound < endIndex { guard let range = self.range(of: string, options: [], range: initialLeftBound..) -> [ClosedRange] { var occurences = [ClosedRange]() var initialLeftBound = startIndex while initialLeftBound < endIndex { guard let beginRange = self.range(of: range.lowerBound, options: [], range: initialLeftBound..) -> [Range] { var occurences = [Range]() var initialLeftBound = startIndex while initialLeftBound < endIndex { guard let beginRange = self.range(of: range.lowerBound, options: [], range: initialLeftBound.. [String.Index] { var occurences = [String.Index]() var initialLeftBound = startIndex while initialLeftBound < endIndex { guard let beginRange = self.range(of: String(character), options: [], range: initialLeftBound..) -> PartialRangeFrom? { guard self.indexOffset(by: range.lowerBound.count) != nil else { return nil } guard let beginRange = self.range(of: range.lowerBound, options: [], range: startIndex..) -> PartialRangeThrough? { guard self.indexOffset(by: range.upperBound.count) != nil else { return nil } guard let endRange = self.range(of: range.upperBound, options: [], range: startIndex.. String.Index? { return index(startIndex, offsetBy: distance, limitedBy: endIndex) } } ================================================ FILE: Stryng.podspec ================================================ Pod::Spec.new do |s| s.name = "Stryng" s.version = "0.4" s.summary = "Stop crying when accessing Swift Strings." s.description = <<-DESC Stryng is designed to make it easier to work with strings by using the common and easy to remember subscript syntax and accessing characters and ranges with Int indices. DESC s.homepage = "https://github.com/BalestraPatrick/Stryng" s.license = { :type => "MIT", :file => "LICENSE" } s.author = { "Patrick Balestra" => "me@patrickbalestra.com" } s.social_media_url = "" s.ios.deployment_target = "8.0" s.osx.deployment_target = "10.9" s.watchos.deployment_target = "2.0" s.tvos.deployment_target = "9.0" s.source = { :git => "https://github.com/BalestraPatrick/Stryng.git", :tag => s.version.to_s } s.source_files = "Sources/**/*" s.frameworks = "Foundation" end ================================================ FILE: Stryng.xcodeproj/project.pbxproj ================================================ // !$*UTF8*$! { archiveVersion = 1; classes = { }; objectVersion = 47; objects = { /* Begin PBXBuildFile section */ 52D6D9871BEFF229002C0205 /* Stryng.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 52D6D97C1BEFF229002C0205 /* Stryng.framework */; }; 8933C7851EB5B820000D00A4 /* Stryng.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8933C7841EB5B820000D00A4 /* Stryng.swift */; }; 8933C7861EB5B820000D00A4 /* Stryng.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8933C7841EB5B820000D00A4 /* Stryng.swift */; }; 8933C7871EB5B820000D00A4 /* Stryng.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8933C7841EB5B820000D00A4 /* Stryng.swift */; }; 8933C7881EB5B820000D00A4 /* Stryng.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8933C7841EB5B820000D00A4 /* Stryng.swift */; }; 8933C78E1EB5B82C000D00A4 /* StryngTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8933C7891EB5B82A000D00A4 /* StryngTests.swift */; }; 8933C78F1EB5B82C000D00A4 /* StryngTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8933C7891EB5B82A000D00A4 /* StryngTests.swift */; }; 8933C7901EB5B82D000D00A4 /* StryngTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8933C7891EB5B82A000D00A4 /* StryngTests.swift */; }; AEE9F81D212F19F60003A83C /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = AEE9F81C212F19F60003A83C /* Foundation.framework */; }; AEE9F81F212F19FC0003A83C /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = AEE9F81E212F19FC0003A83C /* Foundation.framework */; }; AEE9F821212F1A020003A83C /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = AEE9F820212F1A020003A83C /* Foundation.framework */; }; AEE9F823212F1A090003A83C /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = AEE9F822212F1A090003A83C /* Foundation.framework */; }; DD7502881C68FEDE006590AF /* Stryng.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 52D6DA0F1BF000BD002C0205 /* Stryng.framework */; }; DD7502921C690C7A006590AF /* Stryng.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 52D6D9F01BEFFFBE002C0205 /* Stryng.framework */; }; /* End PBXBuildFile section */ /* Begin PBXContainerItemProxy section */ 52D6D9881BEFF229002C0205 /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 52D6D9731BEFF229002C0205 /* Project object */; proxyType = 1; remoteGlobalIDString = 52D6D97B1BEFF229002C0205; remoteInfo = Stryng; }; DD7502801C68FCFC006590AF /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 52D6D9731BEFF229002C0205 /* Project object */; proxyType = 1; remoteGlobalIDString = 52D6DA0E1BF000BD002C0205; remoteInfo = "Stryng-macOS"; }; DD7502931C690C7A006590AF /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 52D6D9731BEFF229002C0205 /* Project object */; proxyType = 1; remoteGlobalIDString = 52D6D9EF1BEFFFBE002C0205; remoteInfo = "Stryng-tvOS"; }; /* End PBXContainerItemProxy section */ /* Begin PBXFileReference section */ 52D6D97C1BEFF229002C0205 /* Stryng.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Stryng.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 52D6D9861BEFF229002C0205 /* Stryng-iOS Tests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "Stryng-iOS Tests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; }; 52D6D9E21BEFFF6E002C0205 /* Stryng.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Stryng.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 52D6D9F01BEFFFBE002C0205 /* Stryng.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Stryng.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 52D6DA0F1BF000BD002C0205 /* Stryng.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Stryng.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 8933C7841EB5B820000D00A4 /* Stryng.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Stryng.swift; sourceTree = ""; }; 8933C7891EB5B82A000D00A4 /* StryngTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = StryngTests.swift; sourceTree = ""; }; AD2FAA261CD0B6D800659CF4 /* Stryng.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Stryng.plist; sourceTree = ""; }; AD2FAA281CD0B6E100659CF4 /* StryngTests.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = StryngTests.plist; sourceTree = ""; }; AEE9F81C212F19F60003A83C /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; AEE9F81E212F19FC0003A83C /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Foundation.framework; sourceTree = DEVELOPER_DIR; }; AEE9F820212F1A020003A83C /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = Platforms/WatchOS.platform/Developer/SDKs/WatchOS5.0.sdk/System/Library/Frameworks/Foundation.framework; sourceTree = DEVELOPER_DIR; }; AEE9F822212F1A090003A83C /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS12.0.sdk/System/Library/Frameworks/Foundation.framework; sourceTree = DEVELOPER_DIR; }; DD75027A1C68FCFC006590AF /* Stryng-macOS Tests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "Stryng-macOS Tests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; }; DD75028D1C690C7A006590AF /* Stryng-tvOS Tests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "Stryng-tvOS Tests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ 52D6D9781BEFF229002C0205 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( AEE9F81D212F19F60003A83C /* Foundation.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; 52D6D9831BEFF229002C0205 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( 52D6D9871BEFF229002C0205 /* Stryng.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; 52D6D9DE1BEFFF6E002C0205 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( AEE9F821212F1A020003A83C /* Foundation.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; 52D6D9EC1BEFFFBE002C0205 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( AEE9F823212F1A090003A83C /* Foundation.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; 52D6DA0B1BF000BD002C0205 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( AEE9F81F212F19FC0003A83C /* Foundation.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; DD7502771C68FCFC006590AF /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( DD7502881C68FEDE006590AF /* Stryng.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; DD75028A1C690C7A006590AF /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( DD7502921C690C7A006590AF /* Stryng.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXFrameworksBuildPhase section */ /* Begin PBXGroup section */ 52D6D9721BEFF229002C0205 = { isa = PBXGroup; children = ( 8933C7811EB5B7E0000D00A4 /* Sources */, 8933C7831EB5B7EB000D00A4 /* Tests */, 52D6D99C1BEFF38C002C0205 /* Configs */, 52D6D97D1BEFF229002C0205 /* Products */, AEE9F81B212F19F60003A83C /* Frameworks */, ); sourceTree = ""; }; 52D6D97D1BEFF229002C0205 /* Products */ = { isa = PBXGroup; children = ( 52D6D97C1BEFF229002C0205 /* Stryng.framework */, 52D6D9861BEFF229002C0205 /* Stryng-iOS Tests.xctest */, 52D6D9E21BEFFF6E002C0205 /* Stryng.framework */, 52D6D9F01BEFFFBE002C0205 /* Stryng.framework */, 52D6DA0F1BF000BD002C0205 /* Stryng.framework */, DD75027A1C68FCFC006590AF /* Stryng-macOS Tests.xctest */, DD75028D1C690C7A006590AF /* Stryng-tvOS Tests.xctest */, ); name = Products; sourceTree = ""; }; 52D6D99C1BEFF38C002C0205 /* Configs */ = { isa = PBXGroup; children = ( DD7502721C68FC1B006590AF /* Frameworks */, DD7502731C68FC20006590AF /* Tests */, ); path = Configs; sourceTree = ""; }; 8933C7811EB5B7E0000D00A4 /* Sources */ = { isa = PBXGroup; children = ( 8933C7841EB5B820000D00A4 /* Stryng.swift */, ); path = Sources; sourceTree = ""; }; 8933C7831EB5B7EB000D00A4 /* Tests */ = { isa = PBXGroup; children = ( 8933C7891EB5B82A000D00A4 /* StryngTests.swift */, ); name = Tests; path = Tests/StryngTests; sourceTree = ""; }; AEE9F81B212F19F60003A83C /* Frameworks */ = { isa = PBXGroup; children = ( AEE9F822212F1A090003A83C /* Foundation.framework */, AEE9F820212F1A020003A83C /* Foundation.framework */, AEE9F81E212F19FC0003A83C /* Foundation.framework */, AEE9F81C212F19F60003A83C /* Foundation.framework */, ); name = Frameworks; sourceTree = ""; }; DD7502721C68FC1B006590AF /* Frameworks */ = { isa = PBXGroup; children = ( AD2FAA261CD0B6D800659CF4 /* Stryng.plist */, ); name = Frameworks; sourceTree = ""; }; DD7502731C68FC20006590AF /* Tests */ = { isa = PBXGroup; children = ( AD2FAA281CD0B6E100659CF4 /* StryngTests.plist */, ); name = Tests; sourceTree = ""; }; /* End PBXGroup section */ /* Begin PBXHeadersBuildPhase section */ 52D6D9791BEFF229002C0205 /* Headers */ = { isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( ); runOnlyForDeploymentPostprocessing = 0; }; 52D6D9DF1BEFFF6E002C0205 /* Headers */ = { isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( ); runOnlyForDeploymentPostprocessing = 0; }; 52D6D9ED1BEFFFBE002C0205 /* Headers */ = { isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( ); runOnlyForDeploymentPostprocessing = 0; }; 52D6DA0C1BF000BD002C0205 /* Headers */ = { isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXHeadersBuildPhase section */ /* Begin PBXNativeTarget section */ 52D6D97B1BEFF229002C0205 /* Stryng-iOS */ = { isa = PBXNativeTarget; buildConfigurationList = 52D6D9901BEFF229002C0205 /* Build configuration list for PBXNativeTarget "Stryng-iOS" */; buildPhases = ( 52D6D9771BEFF229002C0205 /* Sources */, 52D6D9781BEFF229002C0205 /* Frameworks */, 52D6D9791BEFF229002C0205 /* Headers */, 52D6D97A1BEFF229002C0205 /* Resources */, ); buildRules = ( ); dependencies = ( ); name = "Stryng-iOS"; productName = Stryng; productReference = 52D6D97C1BEFF229002C0205 /* Stryng.framework */; productType = "com.apple.product-type.framework"; }; 52D6D9851BEFF229002C0205 /* Stryng-iOS Tests */ = { isa = PBXNativeTarget; buildConfigurationList = 52D6D9931BEFF229002C0205 /* Build configuration list for PBXNativeTarget "Stryng-iOS Tests" */; buildPhases = ( 52D6D9821BEFF229002C0205 /* Sources */, 52D6D9831BEFF229002C0205 /* Frameworks */, 52D6D9841BEFF229002C0205 /* Resources */, ); buildRules = ( ); dependencies = ( 52D6D9891BEFF229002C0205 /* PBXTargetDependency */, ); name = "Stryng-iOS Tests"; productName = StryngTests; productReference = 52D6D9861BEFF229002C0205 /* Stryng-iOS Tests.xctest */; productType = "com.apple.product-type.bundle.unit-test"; }; 52D6D9E11BEFFF6E002C0205 /* Stryng-watchOS */ = { isa = PBXNativeTarget; buildConfigurationList = 52D6D9E71BEFFF6E002C0205 /* Build configuration list for PBXNativeTarget "Stryng-watchOS" */; buildPhases = ( 52D6D9DD1BEFFF6E002C0205 /* Sources */, 52D6D9DE1BEFFF6E002C0205 /* Frameworks */, 52D6D9DF1BEFFF6E002C0205 /* Headers */, 52D6D9E01BEFFF6E002C0205 /* Resources */, ); buildRules = ( ); dependencies = ( ); name = "Stryng-watchOS"; productName = "Stryng-watchOS"; productReference = 52D6D9E21BEFFF6E002C0205 /* Stryng.framework */; productType = "com.apple.product-type.framework"; }; 52D6D9EF1BEFFFBE002C0205 /* Stryng-tvOS */ = { isa = PBXNativeTarget; buildConfigurationList = 52D6DA011BEFFFBE002C0205 /* Build configuration list for PBXNativeTarget "Stryng-tvOS" */; buildPhases = ( 52D6D9EB1BEFFFBE002C0205 /* Sources */, 52D6D9EC1BEFFFBE002C0205 /* Frameworks */, 52D6D9ED1BEFFFBE002C0205 /* Headers */, 52D6D9EE1BEFFFBE002C0205 /* Resources */, ); buildRules = ( ); dependencies = ( ); name = "Stryng-tvOS"; productName = "Stryng-tvOS"; productReference = 52D6D9F01BEFFFBE002C0205 /* Stryng.framework */; productType = "com.apple.product-type.framework"; }; 52D6DA0E1BF000BD002C0205 /* Stryng-macOS */ = { isa = PBXNativeTarget; buildConfigurationList = 52D6DA201BF000BD002C0205 /* Build configuration list for PBXNativeTarget "Stryng-macOS" */; buildPhases = ( 52D6DA0A1BF000BD002C0205 /* Sources */, 52D6DA0B1BF000BD002C0205 /* Frameworks */, 52D6DA0C1BF000BD002C0205 /* Headers */, 52D6DA0D1BF000BD002C0205 /* Resources */, ); buildRules = ( ); dependencies = ( ); name = "Stryng-macOS"; productName = "Stryng-macOS"; productReference = 52D6DA0F1BF000BD002C0205 /* Stryng.framework */; productType = "com.apple.product-type.framework"; }; DD7502791C68FCFC006590AF /* Stryng-macOS Tests */ = { isa = PBXNativeTarget; buildConfigurationList = DD7502821C68FCFC006590AF /* Build configuration list for PBXNativeTarget "Stryng-macOS Tests" */; buildPhases = ( DD7502761C68FCFC006590AF /* Sources */, DD7502771C68FCFC006590AF /* Frameworks */, DD7502781C68FCFC006590AF /* Resources */, ); buildRules = ( ); dependencies = ( DD7502811C68FCFC006590AF /* PBXTargetDependency */, ); name = "Stryng-macOS Tests"; productName = "Stryng-OS Tests"; productReference = DD75027A1C68FCFC006590AF /* Stryng-macOS Tests.xctest */; productType = "com.apple.product-type.bundle.unit-test"; }; DD75028C1C690C7A006590AF /* Stryng-tvOS Tests */ = { isa = PBXNativeTarget; buildConfigurationList = DD7502951C690C7A006590AF /* Build configuration list for PBXNativeTarget "Stryng-tvOS Tests" */; buildPhases = ( DD7502891C690C7A006590AF /* Sources */, DD75028A1C690C7A006590AF /* Frameworks */, DD75028B1C690C7A006590AF /* Resources */, ); buildRules = ( ); dependencies = ( DD7502941C690C7A006590AF /* PBXTargetDependency */, ); name = "Stryng-tvOS Tests"; productName = "Stryng-tvOS Tests"; productReference = DD75028D1C690C7A006590AF /* Stryng-tvOS Tests.xctest */; productType = "com.apple.product-type.bundle.unit-test"; }; /* End PBXNativeTarget section */ /* Begin PBXProject section */ 52D6D9731BEFF229002C0205 /* Project object */ = { isa = PBXProject; attributes = { LastSwiftUpdateCheck = 0720; LastUpgradeCheck = 1000; ORGANIZATIONNAME = Stryng; TargetAttributes = { 52D6D97B1BEFF229002C0205 = { CreatedOnToolsVersion = 7.1; LastSwiftMigration = 1000; }; 52D6D9851BEFF229002C0205 = { CreatedOnToolsVersion = 7.1; LastSwiftMigration = 1000; }; 52D6D9E11BEFFF6E002C0205 = { CreatedOnToolsVersion = 7.1; LastSwiftMigration = 0800; }; 52D6D9EF1BEFFFBE002C0205 = { CreatedOnToolsVersion = 7.1; LastSwiftMigration = 0800; }; 52D6DA0E1BF000BD002C0205 = { CreatedOnToolsVersion = 7.1; LastSwiftMigration = 0800; }; DD7502791C68FCFC006590AF = { CreatedOnToolsVersion = 7.2.1; LastSwiftMigration = 0800; }; DD75028C1C690C7A006590AF = { CreatedOnToolsVersion = 7.2.1; LastSwiftMigration = 0800; }; }; }; buildConfigurationList = 52D6D9761BEFF229002C0205 /* Build configuration list for PBXProject "Stryng" */; compatibilityVersion = "Xcode 6.3"; developmentRegion = English; hasScannedForEncodings = 0; knownRegions = ( en, ); mainGroup = 52D6D9721BEFF229002C0205; productRefGroup = 52D6D97D1BEFF229002C0205 /* Products */; projectDirPath = ""; projectRoot = ""; targets = ( 52D6D97B1BEFF229002C0205 /* Stryng-iOS */, 52D6DA0E1BF000BD002C0205 /* Stryng-macOS */, 52D6D9E11BEFFF6E002C0205 /* Stryng-watchOS */, 52D6D9EF1BEFFFBE002C0205 /* Stryng-tvOS */, 52D6D9851BEFF229002C0205 /* Stryng-iOS Tests */, DD7502791C68FCFC006590AF /* Stryng-macOS Tests */, DD75028C1C690C7A006590AF /* Stryng-tvOS Tests */, ); }; /* End PBXProject section */ /* Begin PBXResourcesBuildPhase section */ 52D6D97A1BEFF229002C0205 /* Resources */ = { isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( ); runOnlyForDeploymentPostprocessing = 0; }; 52D6D9841BEFF229002C0205 /* Resources */ = { isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( ); runOnlyForDeploymentPostprocessing = 0; }; 52D6D9E01BEFFF6E002C0205 /* Resources */ = { isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( ); runOnlyForDeploymentPostprocessing = 0; }; 52D6D9EE1BEFFFBE002C0205 /* Resources */ = { isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( ); runOnlyForDeploymentPostprocessing = 0; }; 52D6DA0D1BF000BD002C0205 /* Resources */ = { isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( ); runOnlyForDeploymentPostprocessing = 0; }; DD7502781C68FCFC006590AF /* Resources */ = { isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( ); runOnlyForDeploymentPostprocessing = 0; }; DD75028B1C690C7A006590AF /* Resources */ = { isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXResourcesBuildPhase section */ /* Begin PBXSourcesBuildPhase section */ 52D6D9771BEFF229002C0205 /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( 8933C7851EB5B820000D00A4 /* Stryng.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; 52D6D9821BEFF229002C0205 /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( 8933C7901EB5B82D000D00A4 /* StryngTests.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; 52D6D9DD1BEFFF6E002C0205 /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( 8933C7871EB5B820000D00A4 /* Stryng.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; 52D6D9EB1BEFFFBE002C0205 /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( 8933C7881EB5B820000D00A4 /* Stryng.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; 52D6DA0A1BF000BD002C0205 /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( 8933C7861EB5B820000D00A4 /* Stryng.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; DD7502761C68FCFC006590AF /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( 8933C78F1EB5B82C000D00A4 /* StryngTests.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; DD7502891C690C7A006590AF /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( 8933C78E1EB5B82C000D00A4 /* StryngTests.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXSourcesBuildPhase section */ /* Begin PBXTargetDependency section */ 52D6D9891BEFF229002C0205 /* PBXTargetDependency */ = { isa = PBXTargetDependency; target = 52D6D97B1BEFF229002C0205 /* Stryng-iOS */; targetProxy = 52D6D9881BEFF229002C0205 /* PBXContainerItemProxy */; }; DD7502811C68FCFC006590AF /* PBXTargetDependency */ = { isa = PBXTargetDependency; target = 52D6DA0E1BF000BD002C0205 /* Stryng-macOS */; targetProxy = DD7502801C68FCFC006590AF /* PBXContainerItemProxy */; }; DD7502941C690C7A006590AF /* PBXTargetDependency */ = { isa = PBXTargetDependency; target = 52D6D9EF1BEFFFBE002C0205 /* Stryng-tvOS */; targetProxy = DD7502931C690C7A006590AF /* PBXContainerItemProxy */; }; /* End PBXTargetDependency section */ /* Begin XCBuildConfiguration section */ 52D6D98E1BEFF229002C0205 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_BOOL_CONVERSION = YES; CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; CLANG_WARN_STRICT_PROTOTYPES = YES; CLANG_WARN_SUSPICIOUS_MOVE = YES; 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 = 8.0; MTL_ENABLE_DEBUG_INFO = YES; ONLY_ACTIVE_ARCH = YES; SDKROOT = iphoneos; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 4.0; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Debug; }; 52D6D98F1BEFF229002C0205 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_BOOL_CONVERSION = YES; CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; CLANG_WARN_STRICT_PROTOTYPES = YES; CLANG_WARN_SUSPICIOUS_MOVE = YES; 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 = 8.0; MTL_ENABLE_DEBUG_INFO = NO; SDKROOT = iphoneos; SWIFT_VERSION = 4.0; TARGETED_DEVICE_FAMILY = "1,2"; VALIDATE_PRODUCT = YES; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Release; }; 52D6D9911BEFF229002C0205 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; CLANG_ENABLE_MODULES = YES; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; INFOPLIST_FILE = Configs/Stryng.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; ONLY_ACTIVE_ARCH = NO; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-iOS"; PRODUCT_NAME = Stryng; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 4.2; }; name = Debug; }; 52D6D9921BEFF229002C0205 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; CLANG_ENABLE_MODULES = YES; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; INFOPLIST_FILE = Configs/Stryng.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-iOS"; PRODUCT_NAME = Stryng; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; SWIFT_VERSION = 4.2; }; name = Release; }; 52D6D9941BEFF229002C0205 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { CLANG_ENABLE_MODULES = YES; INFOPLIST_FILE = Configs/StryngTests.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-iOS-Tests"; PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 4.2; }; name = Debug; }; 52D6D9951BEFF229002C0205 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { CLANG_ENABLE_MODULES = YES; INFOPLIST_FILE = Configs/StryngTests.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-iOS-Tests"; PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; SWIFT_VERSION = 4.2; }; name = Release; }; 52D6D9E81BEFFF6E002C0205 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; INFOPLIST_FILE = Configs/Stryng.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-watchOS"; PRODUCT_NAME = Stryng; SDKROOT = watchos; SKIP_INSTALL = YES; SWIFT_VERSION = 4.2; TARGETED_DEVICE_FAMILY = 4; WATCHOS_DEPLOYMENT_TARGET = 2.0; }; name = Debug; }; 52D6D9E91BEFFF6E002C0205 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; INFOPLIST_FILE = Configs/Stryng.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-watchOS"; PRODUCT_NAME = Stryng; SDKROOT = watchos; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; SWIFT_VERSION = 4.2; TARGETED_DEVICE_FAMILY = 4; WATCHOS_DEPLOYMENT_TARGET = 2.0; }; name = Release; }; 52D6DA021BEFFFBE002C0205 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; INFOPLIST_FILE = Configs/Stryng.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-tvOS"; PRODUCT_NAME = Stryng; SDKROOT = appletvos; SKIP_INSTALL = YES; SWIFT_VERSION = 4.2; TARGETED_DEVICE_FAMILY = 3; TVOS_DEPLOYMENT_TARGET = 9.0; }; name = Debug; }; 52D6DA031BEFFFBE002C0205 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; INFOPLIST_FILE = Configs/Stryng.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-tvOS"; PRODUCT_NAME = Stryng; SDKROOT = appletvos; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; SWIFT_VERSION = 4.2; TARGETED_DEVICE_FAMILY = 3; TVOS_DEPLOYMENT_TARGET = 9.0; }; name = Release; }; 52D6DA211BF000BD002C0205 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; CODE_SIGN_IDENTITY = "-"; COMBINE_HIDPI_IMAGES = YES; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; FRAMEWORK_VERSION = A; INFOPLIST_FILE = Configs/Stryng.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.10; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-macOS"; PRODUCT_NAME = Stryng; SDKROOT = macosx; SKIP_INSTALL = YES; SWIFT_VERSION = 4.2; }; name = Debug; }; 52D6DA221BF000BD002C0205 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; CODE_SIGN_IDENTITY = "-"; COMBINE_HIDPI_IMAGES = YES; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; FRAMEWORK_VERSION = A; INFOPLIST_FILE = Configs/Stryng.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.10; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-macOS"; PRODUCT_NAME = Stryng; SDKROOT = macosx; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; SWIFT_VERSION = 4.2; }; name = Release; }; DD7502831C68FCFC006590AF /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { CODE_SIGN_IDENTITY = "-"; COMBINE_HIDPI_IMAGES = YES; INFOPLIST_FILE = Configs/StryngTests.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/../Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.11; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-macOS-Tests"; PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = macosx; SWIFT_VERSION = 4.2; }; name = Debug; }; DD7502841C68FCFC006590AF /* Release */ = { isa = XCBuildConfiguration; buildSettings = { CODE_SIGN_IDENTITY = "-"; COMBINE_HIDPI_IMAGES = YES; INFOPLIST_FILE = Configs/StryngTests.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/../Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.11; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-macOS-Tests"; PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = macosx; SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; SWIFT_VERSION = 4.2; }; name = Release; }; DD7502961C690C7A006590AF /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { INFOPLIST_FILE = Configs/StryngTests.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-tvOS-Tests"; PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = appletvos; SWIFT_VERSION = 4.2; TVOS_DEPLOYMENT_TARGET = 9.1; }; name = Debug; }; DD7502971C690C7A006590AF /* Release */ = { isa = XCBuildConfiguration; buildSettings = { INFOPLIST_FILE = Configs/StryngTests.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "com.Stryng.Stryng-tvOS-Tests"; PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = appletvos; SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; SWIFT_VERSION = 4.2; TVOS_DEPLOYMENT_TARGET = 9.1; }; name = Release; }; /* End XCBuildConfiguration section */ /* Begin XCConfigurationList section */ 52D6D9761BEFF229002C0205 /* Build configuration list for PBXProject "Stryng" */ = { isa = XCConfigurationList; buildConfigurations = ( 52D6D98E1BEFF229002C0205 /* Debug */, 52D6D98F1BEFF229002C0205 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; 52D6D9901BEFF229002C0205 /* Build configuration list for PBXNativeTarget "Stryng-iOS" */ = { isa = XCConfigurationList; buildConfigurations = ( 52D6D9911BEFF229002C0205 /* Debug */, 52D6D9921BEFF229002C0205 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; 52D6D9931BEFF229002C0205 /* Build configuration list for PBXNativeTarget "Stryng-iOS Tests" */ = { isa = XCConfigurationList; buildConfigurations = ( 52D6D9941BEFF229002C0205 /* Debug */, 52D6D9951BEFF229002C0205 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; 52D6D9E71BEFFF6E002C0205 /* Build configuration list for PBXNativeTarget "Stryng-watchOS" */ = { isa = XCConfigurationList; buildConfigurations = ( 52D6D9E81BEFFF6E002C0205 /* Debug */, 52D6D9E91BEFFF6E002C0205 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; 52D6DA011BEFFFBE002C0205 /* Build configuration list for PBXNativeTarget "Stryng-tvOS" */ = { isa = XCConfigurationList; buildConfigurations = ( 52D6DA021BEFFFBE002C0205 /* Debug */, 52D6DA031BEFFFBE002C0205 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; 52D6DA201BF000BD002C0205 /* Build configuration list for PBXNativeTarget "Stryng-macOS" */ = { isa = XCConfigurationList; buildConfigurations = ( 52D6DA211BF000BD002C0205 /* Debug */, 52D6DA221BF000BD002C0205 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; DD7502821C68FCFC006590AF /* Build configuration list for PBXNativeTarget "Stryng-macOS Tests" */ = { isa = XCConfigurationList; buildConfigurations = ( DD7502831C68FCFC006590AF /* Debug */, DD7502841C68FCFC006590AF /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; DD7502951C690C7A006590AF /* Build configuration list for PBXNativeTarget "Stryng-tvOS Tests" */ = { isa = XCConfigurationList; buildConfigurations = ( DD7502961C690C7A006590AF /* Debug */, DD7502971C690C7A006590AF /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; /* End XCConfigurationList section */ }; rootObject = 52D6D9731BEFF229002C0205 /* Project object */; } ================================================ FILE: Stryng.xcodeproj/project.xcworkspace/contents.xcworkspacedata ================================================ ================================================ FILE: Stryng.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist ================================================ IDEDidComputeMac32BitWarning ================================================ FILE: Stryng.xcodeproj/xcshareddata/xcschemes/Stryng-iOS.xcscheme ================================================ ================================================ FILE: Stryng.xcodeproj/xcshareddata/xcschemes/Stryng-macOS.xcscheme ================================================ ================================================ FILE: Stryng.xcodeproj/xcshareddata/xcschemes/Stryng-tvOS.xcscheme ================================================ ================================================ FILE: Stryng.xcodeproj/xcshareddata/xcschemes/Stryng-watchOS.xcscheme ================================================ ================================================ FILE: Tests/LinuxMain.swift ================================================ import XCTest @testable import StryngTests XCTMain([ testCase(StryngTests.allTests), ]) ================================================ FILE: Tests/StryngTests/StryngTests.swift ================================================ // // StryngTests.swift // Stryng // // Created by Patrick Balestra on 12/2/17. // Copyright © 2017 Stryng. All rights reserved. // import Foundation import XCTest import Stryng class StryngTests: XCTestCase { func testIndex() { let example = "Example" XCTAssertEqual(example[1], "x") } func testEmptyStringIndexOutOfBounds() { let example = "" XCTAssertNil(example[0]) XCTAssertNil(example[1]) } func testIndexOutOfBounds() { let example = "Example" XCTAssertNil(example[7]) XCTAssertNil(example[8]) } func testRange() { let example = "Example" XCTAssertEqual(example[0..<2], "Ex") } func testRangeEmpty() { let example = "Example" XCTAssertEqual(example[0..<0], "") } func testRangeOutOfBounds() { let example = "Example" XCTAssertNil(example[10..<12]) XCTAssertNil(example[0..<12]) } func testRangeNegative() { let example = "Example" XCTAssertEqual(example[..<(-1)], "Exampl") XCTAssertEqual(example[..<(-3)], "Exam") } func testClosedRangeEmoji() { let example = "👨‍👩‍👧‍👧" XCTAssertEqual(example[0...0], "👨‍👩‍👧‍👧") } func testClosedRangeOutOfBounds() { let example = "Example" XCTAssertNil(example[0...8]) XCTAssertNil(example[10...11]) } func testClosedRangeNegative() { let example = "Example" XCTAssertEqual(example[-2...(-1)], "le") XCTAssertEqual(example[-4...(-1)], "mple") XCTAssertNil(example[-10...(-1)]) } func testPartialRangeUpTo() { let example = "Example" let result = example[..<1] XCTAssertEqual(result, "E") } func testPartialRangeUpToOutOfBounds() { let example = "Example" let result = example[..<8] XCTAssertNil(result) } func testPartialRangeThroughTo() { let example = "Example" let result = example[...1] XCTAssertEqual(result, "Ex") } func testPartialRangeThroughToOutOfBounds() { let example = "Example" let result = example[...8] XCTAssertNil(result) } func testPartialRangeFrom() { let example = "Example" let result = example[1...] XCTAssertEqual(result, "xample") } func testPartialRangeFromOutOfBounds() { let example = "Example" let result = example[10...] XCTAssertNil(result) } func testSubstringOccurence() { let example = "Example" let occurence = example["xa"].first let left = example.distance(from: example.startIndex, to: occurence!.lowerBound) let right = example.distance(from: example.startIndex, to: occurence!.upperBound) XCTAssertEqual(left, 1) XCTAssertEqual(right, 3) XCTAssertEqual(example[left..