├── .gitignore ├── .swift-version ├── .travis.yml ├── AACoreData.podspec ├── AACoreData ├── Assets │ └── .gitkeep └── Classes │ ├── .gitkeep │ ├── AACoreData+Helper.swift │ └── AACoreData.swift ├── Example ├── AACoreData.xcodeproj │ ├── project.pbxproj │ └── project.xcworkspace │ │ └── contents.xcworkspacedata ├── AACoreData.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ ├── IDEWorkspaceChecks.plist │ │ └── WorkspaceSettings.xcsettings ├── AACoreData │ ├── AppDelegate.swift │ ├── Base.lproj │ │ ├── LaunchScreen.xib │ │ └── Main.storyboard │ ├── Constants.swift │ ├── ExampleDataModel.xcdatamodeld │ │ └── ExampleDataModel.xcdatamodel │ │ │ └── contents │ ├── Images.xcassets │ │ ├── AA.imageset │ │ │ ├── 17049477.png │ │ │ └── Contents.json │ │ ├── AppIcon.appiconset │ │ │ ├── Contents.json │ │ │ ├── Icon-App-20x20@1x.png │ │ │ ├── Icon-App-20x20@2x.png │ │ │ ├── Icon-App-20x20@3x.png │ │ │ ├── Icon-App-29x29@1x.png │ │ │ ├── Icon-App-29x29@2x.png │ │ │ ├── Icon-App-29x29@3x.png │ │ │ ├── Icon-App-40x40@1x.png │ │ │ ├── Icon-App-40x40@2x.png │ │ │ ├── Icon-App-40x40@3x.png │ │ │ ├── Icon-App-57x57@1x.png │ │ │ ├── Icon-App-57x57@2x.png │ │ │ ├── Icon-App-60x60@2x.png │ │ │ ├── Icon-App-60x60@3x.png │ │ │ ├── Icon-App-72x72@1x.png │ │ │ ├── Icon-App-72x72@2x.png │ │ │ ├── Icon-App-76x76@1x.png │ │ │ ├── Icon-App-76x76@2x.png │ │ │ ├── Icon-App-83.5x83.5@2x.png │ │ │ ├── Icon-Small-50x50@1x.png │ │ │ └── Icon-Small-50x50@2x.png │ │ └── Contents.json │ ├── Info.plist │ └── TableViewController.swift ├── Podfile ├── Podfile.lock └── Pods │ ├── Local Podspecs │ └── AACoreData.podspec.json │ ├── Manifest.lock │ ├── Pods.xcodeproj │ ├── project.pbxproj │ └── xcshareddata │ │ └── xcschemes │ │ └── AACoreData.xcscheme │ └── Target Support Files │ ├── AACoreData │ ├── AACoreData-dummy.m │ ├── AACoreData-prefix.pch │ ├── AACoreData-umbrella.h │ ├── AACoreData.modulemap │ ├── AACoreData.xcconfig │ └── Info.plist │ └── Pods-AACoreData_Example │ ├── Info.plist │ ├── Pods-AACoreData_Example-acknowledgements.markdown │ ├── Pods-AACoreData_Example-acknowledgements.plist │ ├── Pods-AACoreData_Example-dummy.m │ ├── Pods-AACoreData_Example-frameworks.sh │ ├── Pods-AACoreData_Example-resources.sh │ ├── Pods-AACoreData_Example-umbrella.h │ ├── Pods-AACoreData_Example.debug.xcconfig │ ├── Pods-AACoreData_Example.modulemap │ └── Pods-AACoreData_Example.release.xcconfig ├── LICENSE ├── README.md ├── Screenshots └── demo.gif └── _Pods.xcodeproj /.gitignore: -------------------------------------------------------------------------------- 1 | # OS X 2 | .DS_Store 3 | 4 | # Xcode 5 | build/ 6 | *.pbxuser 7 | !default.pbxuser 8 | *.mode1v3 9 | !default.mode1v3 10 | *.mode2v3 11 | !default.mode2v3 12 | *.perspectivev3 13 | !default.perspectivev3 14 | xcuserdata/ 15 | *.xccheckout 16 | profile 17 | *.moved-aside 18 | DerivedData 19 | *.hmap 20 | *.ipa 21 | 22 | # Bundler 23 | .bundle 24 | 25 | Carthage 26 | # We recommend against adding the Pods directory to your .gitignore. However 27 | # you should judge for yourself, the pros and cons are mentioned at: 28 | # http://guides.cocoapods.org/using/using-cocoapods.html#should-i-ignore-the-pods-directory-in-source-control 29 | # 30 | # Note: if you ignore the Pods directory, make sure to uncomment 31 | # `pod install` in .travis.yml 32 | # 33 | # Pods/ 34 | -------------------------------------------------------------------------------- /.swift-version: -------------------------------------------------------------------------------- 1 | 3.0 2 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | # references: 2 | # * http://www.objc.io/issue-6/travis-ci.html 3 | # * https://github.com/supermarin/xcpretty#usage 4 | 5 | osx_image: xcode7.3 6 | language: objective-c 7 | # cache: cocoapods 8 | # podfile: Example/Podfile 9 | # before_install: 10 | # - gem install cocoapods # Since Travis is not always on latest version 11 | # - pod install --project-directory=Example 12 | script: 13 | - set -o pipefail && xcodebuild test -workspace Example/AACoreData.xcworkspace -scheme AACoreData-Example -sdk iphonesimulator9.3 ONLY_ACTIVE_ARCH=NO | xcpretty 14 | - pod lib lint 15 | -------------------------------------------------------------------------------- /AACoreData.podspec: -------------------------------------------------------------------------------- 1 | 2 | Pod::Spec.new do |s| 3 | s.name = 'AACoreData' 4 | s.version = '1.0' 5 | s.summary = 'AACoreData is a lightweight data persistence wrapper designed to provide an easier solution for `CRUD` operations using CoreData in Swift.' 6 | 7 | s.description = <<-DESC 8 | AACoreData is a lightweight data persistence wrapper designed to provide an easier solution for `CRUD` operations using `CoreData`, written in Swift. It provides a singleton instance to access `CoreData` objects anywhere in the code and uses 'value types' to define `CoreData` entities. 9 | DESC 10 | 11 | s.homepage = 'https://github.com/EngrAhsanAli/AACoreData' 12 | # s.screenshots = 'https://github.com/EngrAhsanAli/AACoreData/blob/master/Screenshots/demo.gif' 13 | s.license = { :type => 'MIT', :file => 'LICENSE' } 14 | s.author = { 'Engr. Ahsan Ali' => 'hafiz.m.ahsan.ali@gmail.com' } 15 | s.source = { :git => 'https://github.com/EngrAhsanAli/AACoreData.git', :tag => s.version.to_s } 16 | 17 | s.ios.deployment_target = '8.0' 18 | 19 | s.source_files = 'AACoreData/Classes/**/*' 20 | 21 | end 22 | -------------------------------------------------------------------------------- /AACoreData/Assets/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/AACoreData/Assets/.gitkeep -------------------------------------------------------------------------------- /AACoreData/Classes/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/AACoreData/Classes/.gitkeep -------------------------------------------------------------------------------- /AACoreData/Classes/AACoreData+Helper.swift: -------------------------------------------------------------------------------- 1 | // 2 | // AACoreData+Helper.swift 3 | // AACoreData 4 | // 5 | // Created by MacBook Pro on 21/09/2018. 6 | // 7 | 8 | import CoreData 9 | 10 | public typealias AACoreEntity = AACoreDataEntity 11 | 12 | // MARK:- AACoreData Entities 13 | open class AACoreDataEntity: AACoreData { 14 | public let _entity: String 15 | 16 | public init(_ entity: String) { 17 | self._entity = entity 18 | super.init() 19 | } 20 | } 21 | 22 | -------------------------------------------------------------------------------- /AACoreData/Classes/AACoreData.swift: -------------------------------------------------------------------------------- 1 | // 2 | // AACoreData.swift 3 | // AA-Creations 4 | // 5 | // Created by Engr. Ahsan Ali on 20/12/2016. 6 | // Copyright © 2016 AA-Creations. All rights reserved. 7 | // 8 | 9 | import Foundation 10 | import CoreData 11 | 12 | open class AACoreData { 13 | 14 | //MARK: Shared Instance 15 | 16 | static public let shared : AACoreData = { 17 | return AACoreData() 18 | }() 19 | 20 | open var dataModel = "AACoreData" 21 | 22 | private lazy var applicationDocumentsDirectory: URL = { 23 | let urls = FileManager.default.urls(for: .documentDirectory, in: .userDomainMask) 24 | return urls[urls.count-1] 25 | }() 26 | 27 | private lazy var managedObjectModel: NSManagedObjectModel = { 28 | let modelURL = Bundle.main.url(forResource: self.dataModel, withExtension: "momd")! 29 | return NSManagedObjectModel(contentsOf: modelURL)! 30 | }() 31 | 32 | private lazy var persistentStoreCoordinator: NSPersistentStoreCoordinator = { 33 | let coordinator = NSPersistentStoreCoordinator(managedObjectModel: self.managedObjectModel) 34 | let url = self.applicationDocumentsDirectory.appendingPathComponent("\(self.dataModel).sqlite") 35 | var failureReason = "AACoreData - There was an error creating or loading the application's saved data." 36 | do { 37 | let options = [ NSMigratePersistentStoresAutomaticallyOption : true, NSInferMappingModelAutomaticallyOption : true ] 38 | try coordinator.addPersistentStore(ofType: NSSQLiteStoreType, configurationName: nil, at: url, options: options) 39 | } catch { 40 | var dict = [String: AnyObject]() 41 | dict[NSLocalizedDescriptionKey] = "AACoreData - Failed to initialize the application's saved data" as AnyObject? 42 | dict[NSLocalizedFailureReasonErrorKey] = failureReason as AnyObject? 43 | 44 | dict[NSUnderlyingErrorKey] = error as NSError 45 | let wrappedError = NSError(domain: "YOUR_ERROR_DOMAIN", code: 9999, userInfo: dict) 46 | NSLog("AACoreData - Unresolved error \(wrappedError), \(wrappedError.userInfo)") 47 | abort() 48 | } 49 | 50 | return coordinator 51 | }() 52 | 53 | open lazy var managedObjectContext: NSManagedObjectContext = { 54 | 55 | var managedObjectContext: NSManagedObjectContext? 56 | if #available(iOS 10.0, *){ 57 | managedObjectContext = self.persistentContainer.viewContext 58 | } 59 | else{ 60 | let coordinator = self.persistentStoreCoordinator 61 | managedObjectContext = NSManagedObjectContext(concurrencyType: .mainQueueConcurrencyType) 62 | managedObjectContext?.persistentStoreCoordinator = coordinator 63 | 64 | } 65 | return managedObjectContext! 66 | }() 67 | 68 | // iOS-10 69 | @available(iOS 10.0, *) 70 | lazy var persistentContainer: NSPersistentContainer = { 71 | let container = NSPersistentContainer(name: self.dataModel) 72 | container.loadPersistentStores(completionHandler: { (storeDescription, error) in 73 | if let error = error as NSError? { 74 | fatalError("AACoreData - Unresolved error \(error), \(error.userInfo)") 75 | } 76 | }) 77 | return container 78 | }() 79 | 80 | 81 | // MARK: - Core Data Saving support 82 | 83 | open func saveContext () { 84 | if managedObjectContext.hasChanges { 85 | do { 86 | try managedObjectContext.save() 87 | } catch { 88 | let nserror = error as NSError 89 | NSLog("AACoreData - Unresolved error \(nserror), \(nserror.userInfo)") 90 | abort() 91 | } 92 | } 93 | } 94 | 95 | } 96 | 97 | // MARK:- AACoreData Wrapper 98 | extension AACoreData { 99 | 100 | open func getNewObject(entityName: AACoreDataEntity) -> NSManagedObject { 101 | return NSEntityDescription.insertNewObject(forEntityName: entityName._entity, into: managedObjectContext) 102 | 103 | } 104 | open func fetchRecords(entityName: AACoreDataEntity, predicate: String? = nil, sortDescriptors: [NSSortDescriptor]? = nil, completion: @escaping (_ records: Any?) -> ()) { 105 | 106 | let fetchRequest = NSFetchRequest(entityName: entityName._entity) 107 | 108 | if let string = predicate { 109 | fetchRequest.predicate = NSPredicate(format: string) 110 | } 111 | 112 | fetchRequest.sortDescriptors = sortDescriptors 113 | 114 | do { 115 | let result = try managedObjectContext.fetch(fetchRequest) 116 | if result.count > 0 { 117 | completion(result) 118 | } 119 | else { 120 | completion(nil) 121 | } 122 | } catch let error as NSError { 123 | print("AACoreData - Fetch failed: \(error.localizedDescription)") 124 | } 125 | } 126 | 127 | open func deleteRecord(_ object: NSManagedObject){ 128 | managedObjectContext.delete(object) 129 | } 130 | 131 | open func deleteAllRecords(entity: AACoreDataEntity) 132 | { 133 | if #available(iOS 9.0, *) { 134 | let req = NSFetchRequest(entityName: entity._entity) 135 | let batchReq = NSBatchDeleteRequest(fetchRequest: req) 136 | execute(batchReq) 137 | } 138 | else { 139 | fetchRecords(entityName: entity, completion: { (results) in 140 | if let records = results as? [NSManagedObject] { 141 | for record in records { 142 | self.deleteRecord(record) 143 | } 144 | } 145 | else { 146 | print("AACoreData - No records found to delete") 147 | } 148 | }) 149 | 150 | } 151 | } 152 | 153 | open func updateRecords(entity: AACoreDataEntity, properties: [AnyHashable : Any]) { 154 | 155 | let batchRequest = NSBatchUpdateRequest(entityName: entity._entity) 156 | batchRequest.propertiesToUpdate = properties 157 | batchRequest.resultType = .updatedObjectsCountResultType 158 | execute(batchRequest) 159 | 160 | } 161 | 162 | open func execute(_ request: NSPersistentStoreRequest) { 163 | do { 164 | try managedObjectContext.execute(request) 165 | } 166 | catch { 167 | print(error) 168 | } 169 | } 170 | 171 | } 172 | -------------------------------------------------------------------------------- /Example/AACoreData.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 424077041E12A74400A7141E /* ExampleDataModel.xcdatamodeld in Sources */ = {isa = PBXBuildFile; fileRef = 424077021E12A74400A7141E /* ExampleDataModel.xcdatamodeld */; }; 11 | 424077061E12AA5600A7141E /* Constants.swift in Sources */ = {isa = PBXBuildFile; fileRef = 424077051E12AA5600A7141E /* Constants.swift */; }; 12 | 4240770A1E12D89800A7141E /* TableViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 424077091E12D89800A7141E /* TableViewController.swift */; }; 13 | 607FACD61AFB9204008FA782 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 607FACD51AFB9204008FA782 /* AppDelegate.swift */; }; 14 | 607FACDB1AFB9204008FA782 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 607FACD91AFB9204008FA782 /* Main.storyboard */; }; 15 | 607FACDD1AFB9204008FA782 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 607FACDC1AFB9204008FA782 /* Images.xcassets */; }; 16 | 607FACE01AFB9204008FA782 /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 607FACDE1AFB9204008FA782 /* LaunchScreen.xib */; }; 17 | 8C6448A659C8416086C716A2 /* Pods_AACoreData_Example.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 612CE8385E55A1AB727BA404 /* Pods_AACoreData_Example.framework */; }; 18 | /* End PBXBuildFile section */ 19 | 20 | /* Begin PBXFileReference section */ 21 | 10507982F6FEBA875F1D00C0 /* README.md */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = net.daringfireball.markdown; name = README.md; path = ../README.md; sourceTree = ""; }; 22 | 23C73AD343CFEB63C1DE3E97 /* AACoreData.podspec */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; name = AACoreData.podspec; path = ../AACoreData.podspec; sourceTree = ""; }; 23 | 2A4940A6A8A5E9483952ADD0 /* Pods-AACoreData_Example.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-AACoreData_Example.debug.xcconfig"; path = "Pods/Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example.debug.xcconfig"; sourceTree = ""; }; 24 | 420E6F021E72F1F7007AEE41 /* AACoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AACoreData.framework; path = ../Carthage/Build/iOS/AACoreData.framework; sourceTree = ""; }; 25 | 424077031E12A74400A7141E /* ExampleDataModel.xcdatamodel */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcdatamodel; path = ExampleDataModel.xcdatamodel; sourceTree = ""; }; 26 | 424077051E12AA5600A7141E /* Constants.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Constants.swift; sourceTree = ""; }; 27 | 424077091E12D89800A7141E /* TableViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TableViewController.swift; sourceTree = ""; }; 28 | 607FACD01AFB9204008FA782 /* AACoreData_Example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = AACoreData_Example.app; sourceTree = BUILT_PRODUCTS_DIR; }; 29 | 607FACD41AFB9204008FA782 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 30 | 607FACD51AFB9204008FA782 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 31 | 607FACDA1AFB9204008FA782 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 32 | 607FACDC1AFB9204008FA782 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = ""; }; 33 | 607FACDF1AFB9204008FA782 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = ""; }; 34 | 612CE8385E55A1AB727BA404 /* Pods_AACoreData_Example.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_AACoreData_Example.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 35 | 746C9CF7E116963A42E9C6DF /* Pods-AACoreData_Tests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-AACoreData_Tests.release.xcconfig"; path = "Pods/Target Support Files/Pods-AACoreData_Tests/Pods-AACoreData_Tests.release.xcconfig"; sourceTree = ""; }; 36 | 95913B80843BC132DA7C881C /* LICENSE */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; name = LICENSE; path = ../LICENSE; sourceTree = ""; }; 37 | A5527CFE0CA65E29D3B457B8 /* Pods-AACoreData_Example.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-AACoreData_Example.release.xcconfig"; path = "Pods/Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example.release.xcconfig"; sourceTree = ""; }; 38 | BBCC978E48B715C9ABF3E519 /* Pods-AACoreData_Tests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-AACoreData_Tests.debug.xcconfig"; path = "Pods/Target Support Files/Pods-AACoreData_Tests/Pods-AACoreData_Tests.debug.xcconfig"; sourceTree = ""; }; 39 | F01AEB76A5C00D81C0F6BED0 /* Pods_AACoreData_Tests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_AACoreData_Tests.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 40 | /* End PBXFileReference section */ 41 | 42 | /* Begin PBXFrameworksBuildPhase section */ 43 | 607FACCD1AFB9204008FA782 /* Frameworks */ = { 44 | isa = PBXFrameworksBuildPhase; 45 | buildActionMask = 2147483647; 46 | files = ( 47 | 8C6448A659C8416086C716A2 /* Pods_AACoreData_Example.framework in Frameworks */, 48 | ); 49 | runOnlyForDeploymentPostprocessing = 0; 50 | }; 51 | /* End PBXFrameworksBuildPhase section */ 52 | 53 | /* Begin PBXGroup section */ 54 | 607FACC71AFB9204008FA782 = { 55 | isa = PBXGroup; 56 | children = ( 57 | 607FACF51AFB993E008FA782 /* Podspec Metadata */, 58 | 607FACD21AFB9204008FA782 /* Example for AACoreData */, 59 | 607FACD11AFB9204008FA782 /* Products */, 60 | 6AA4BC8FE69731A816910ABE /* Pods */, 61 | 97849A62B3EA0D4777160F39 /* Frameworks */, 62 | ); 63 | sourceTree = ""; 64 | }; 65 | 607FACD11AFB9204008FA782 /* Products */ = { 66 | isa = PBXGroup; 67 | children = ( 68 | 607FACD01AFB9204008FA782 /* AACoreData_Example.app */, 69 | ); 70 | name = Products; 71 | sourceTree = ""; 72 | }; 73 | 607FACD21AFB9204008FA782 /* Example for AACoreData */ = { 74 | isa = PBXGroup; 75 | children = ( 76 | 607FACD51AFB9204008FA782 /* AppDelegate.swift */, 77 | 424077051E12AA5600A7141E /* Constants.swift */, 78 | 424077091E12D89800A7141E /* TableViewController.swift */, 79 | 607FACD91AFB9204008FA782 /* Main.storyboard */, 80 | 607FACDC1AFB9204008FA782 /* Images.xcassets */, 81 | 607FACDE1AFB9204008FA782 /* LaunchScreen.xib */, 82 | 424077021E12A74400A7141E /* ExampleDataModel.xcdatamodeld */, 83 | 607FACD31AFB9204008FA782 /* Supporting Files */, 84 | ); 85 | name = "Example for AACoreData"; 86 | path = AACoreData; 87 | sourceTree = ""; 88 | }; 89 | 607FACD31AFB9204008FA782 /* Supporting Files */ = { 90 | isa = PBXGroup; 91 | children = ( 92 | 607FACD41AFB9204008FA782 /* Info.plist */, 93 | ); 94 | name = "Supporting Files"; 95 | sourceTree = ""; 96 | }; 97 | 607FACF51AFB993E008FA782 /* Podspec Metadata */ = { 98 | isa = PBXGroup; 99 | children = ( 100 | 23C73AD343CFEB63C1DE3E97 /* AACoreData.podspec */, 101 | 10507982F6FEBA875F1D00C0 /* README.md */, 102 | 95913B80843BC132DA7C881C /* LICENSE */, 103 | ); 104 | name = "Podspec Metadata"; 105 | sourceTree = ""; 106 | }; 107 | 6AA4BC8FE69731A816910ABE /* Pods */ = { 108 | isa = PBXGroup; 109 | children = ( 110 | 2A4940A6A8A5E9483952ADD0 /* Pods-AACoreData_Example.debug.xcconfig */, 111 | A5527CFE0CA65E29D3B457B8 /* Pods-AACoreData_Example.release.xcconfig */, 112 | BBCC978E48B715C9ABF3E519 /* Pods-AACoreData_Tests.debug.xcconfig */, 113 | 746C9CF7E116963A42E9C6DF /* Pods-AACoreData_Tests.release.xcconfig */, 114 | ); 115 | name = Pods; 116 | sourceTree = ""; 117 | }; 118 | 97849A62B3EA0D4777160F39 /* Frameworks */ = { 119 | isa = PBXGroup; 120 | children = ( 121 | 420E6F021E72F1F7007AEE41 /* AACoreData.framework */, 122 | 612CE8385E55A1AB727BA404 /* Pods_AACoreData_Example.framework */, 123 | F01AEB76A5C00D81C0F6BED0 /* Pods_AACoreData_Tests.framework */, 124 | ); 125 | name = Frameworks; 126 | sourceTree = ""; 127 | }; 128 | /* End PBXGroup section */ 129 | 130 | /* Begin PBXNativeTarget section */ 131 | 607FACCF1AFB9204008FA782 /* AACoreData_Example */ = { 132 | isa = PBXNativeTarget; 133 | buildConfigurationList = 607FACEF1AFB9204008FA782 /* Build configuration list for PBXNativeTarget "AACoreData_Example" */; 134 | buildPhases = ( 135 | 46DEBBDC4B71E80CC65CF7D7 /* [CP] Check Pods Manifest.lock */, 136 | 607FACCC1AFB9204008FA782 /* Sources */, 137 | 607FACCD1AFB9204008FA782 /* Frameworks */, 138 | 607FACCE1AFB9204008FA782 /* Resources */, 139 | CC47213A6106880BA875251C /* [CP] Embed Pods Frameworks */, 140 | 2A3CF4EBC6E6CBB0BCAB6014 /* [CP] Copy Pods Resources */, 141 | ); 142 | buildRules = ( 143 | ); 144 | dependencies = ( 145 | ); 146 | name = AACoreData_Example; 147 | productName = AACoreData; 148 | productReference = 607FACD01AFB9204008FA782 /* AACoreData_Example.app */; 149 | productType = "com.apple.product-type.application"; 150 | }; 151 | /* End PBXNativeTarget section */ 152 | 153 | /* Begin PBXProject section */ 154 | 607FACC81AFB9204008FA782 /* Project object */ = { 155 | isa = PBXProject; 156 | attributes = { 157 | LastSwiftUpdateCheck = 0720; 158 | LastUpgradeCheck = 1020; 159 | ORGANIZATIONNAME = "AA-Creations"; 160 | TargetAttributes = { 161 | 607FACCF1AFB9204008FA782 = { 162 | CreatedOnToolsVersion = 6.3.1; 163 | DevelopmentTeam = 5J29YQGG4K; 164 | LastSwiftMigration = 0940; 165 | ProvisioningStyle = Automatic; 166 | }; 167 | }; 168 | }; 169 | buildConfigurationList = 607FACCB1AFB9204008FA782 /* Build configuration list for PBXProject "AACoreData" */; 170 | compatibilityVersion = "Xcode 3.2"; 171 | developmentRegion = English; 172 | hasScannedForEncodings = 0; 173 | knownRegions = ( 174 | English, 175 | en, 176 | Base, 177 | ); 178 | mainGroup = 607FACC71AFB9204008FA782; 179 | productRefGroup = 607FACD11AFB9204008FA782 /* Products */; 180 | projectDirPath = ""; 181 | projectRoot = ""; 182 | targets = ( 183 | 607FACCF1AFB9204008FA782 /* AACoreData_Example */, 184 | ); 185 | }; 186 | /* End PBXProject section */ 187 | 188 | /* Begin PBXResourcesBuildPhase section */ 189 | 607FACCE1AFB9204008FA782 /* Resources */ = { 190 | isa = PBXResourcesBuildPhase; 191 | buildActionMask = 2147483647; 192 | files = ( 193 | 607FACDB1AFB9204008FA782 /* Main.storyboard in Resources */, 194 | 607FACE01AFB9204008FA782 /* LaunchScreen.xib in Resources */, 195 | 607FACDD1AFB9204008FA782 /* Images.xcassets in Resources */, 196 | ); 197 | runOnlyForDeploymentPostprocessing = 0; 198 | }; 199 | /* End PBXResourcesBuildPhase section */ 200 | 201 | /* Begin PBXShellScriptBuildPhase section */ 202 | 2A3CF4EBC6E6CBB0BCAB6014 /* [CP] Copy Pods Resources */ = { 203 | isa = PBXShellScriptBuildPhase; 204 | buildActionMask = 2147483647; 205 | files = ( 206 | ); 207 | inputPaths = ( 208 | ); 209 | name = "[CP] Copy Pods Resources"; 210 | outputPaths = ( 211 | ); 212 | runOnlyForDeploymentPostprocessing = 0; 213 | shellPath = /bin/sh; 214 | shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example-resources.sh\"\n"; 215 | showEnvVarsInLog = 0; 216 | }; 217 | 46DEBBDC4B71E80CC65CF7D7 /* [CP] Check Pods Manifest.lock */ = { 218 | isa = PBXShellScriptBuildPhase; 219 | buildActionMask = 2147483647; 220 | files = ( 221 | ); 222 | inputPaths = ( 223 | ); 224 | name = "[CP] Check Pods Manifest.lock"; 225 | outputPaths = ( 226 | ); 227 | runOnlyForDeploymentPostprocessing = 0; 228 | shellPath = /bin/sh; 229 | shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n"; 230 | showEnvVarsInLog = 0; 231 | }; 232 | CC47213A6106880BA875251C /* [CP] Embed Pods Frameworks */ = { 233 | isa = PBXShellScriptBuildPhase; 234 | buildActionMask = 2147483647; 235 | files = ( 236 | ); 237 | inputPaths = ( 238 | ); 239 | name = "[CP] Embed Pods Frameworks"; 240 | outputPaths = ( 241 | ); 242 | runOnlyForDeploymentPostprocessing = 0; 243 | shellPath = /bin/sh; 244 | shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example-frameworks.sh\"\n"; 245 | showEnvVarsInLog = 0; 246 | }; 247 | /* End PBXShellScriptBuildPhase section */ 248 | 249 | /* Begin PBXSourcesBuildPhase section */ 250 | 607FACCC1AFB9204008FA782 /* Sources */ = { 251 | isa = PBXSourcesBuildPhase; 252 | buildActionMask = 2147483647; 253 | files = ( 254 | 607FACD61AFB9204008FA782 /* AppDelegate.swift in Sources */, 255 | 424077041E12A74400A7141E /* ExampleDataModel.xcdatamodeld in Sources */, 256 | 4240770A1E12D89800A7141E /* TableViewController.swift in Sources */, 257 | 424077061E12AA5600A7141E /* Constants.swift in Sources */, 258 | ); 259 | runOnlyForDeploymentPostprocessing = 0; 260 | }; 261 | /* End PBXSourcesBuildPhase section */ 262 | 263 | /* Begin PBXVariantGroup section */ 264 | 607FACD91AFB9204008FA782 /* Main.storyboard */ = { 265 | isa = PBXVariantGroup; 266 | children = ( 267 | 607FACDA1AFB9204008FA782 /* Base */, 268 | ); 269 | name = Main.storyboard; 270 | sourceTree = ""; 271 | }; 272 | 607FACDE1AFB9204008FA782 /* LaunchScreen.xib */ = { 273 | isa = PBXVariantGroup; 274 | children = ( 275 | 607FACDF1AFB9204008FA782 /* Base */, 276 | ); 277 | name = LaunchScreen.xib; 278 | sourceTree = ""; 279 | }; 280 | /* End PBXVariantGroup section */ 281 | 282 | /* Begin XCBuildConfiguration section */ 283 | 607FACED1AFB9204008FA782 /* Debug */ = { 284 | isa = XCBuildConfiguration; 285 | buildSettings = { 286 | ALWAYS_SEARCH_USER_PATHS = NO; 287 | CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; 288 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 289 | CLANG_CXX_LIBRARY = "libc++"; 290 | CLANG_ENABLE_MODULES = YES; 291 | CLANG_ENABLE_OBJC_ARC = YES; 292 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 293 | CLANG_WARN_BOOL_CONVERSION = YES; 294 | CLANG_WARN_COMMA = YES; 295 | CLANG_WARN_CONSTANT_CONVERSION = YES; 296 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 297 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 298 | CLANG_WARN_EMPTY_BODY = YES; 299 | CLANG_WARN_ENUM_CONVERSION = YES; 300 | CLANG_WARN_INFINITE_RECURSION = YES; 301 | CLANG_WARN_INT_CONVERSION = YES; 302 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 303 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 304 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 305 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 306 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 307 | CLANG_WARN_STRICT_PROTOTYPES = YES; 308 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 309 | CLANG_WARN_UNREACHABLE_CODE = YES; 310 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 311 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 312 | COPY_PHASE_STRIP = NO; 313 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 314 | ENABLE_STRICT_OBJC_MSGSEND = YES; 315 | ENABLE_TESTABILITY = YES; 316 | GCC_C_LANGUAGE_STANDARD = gnu99; 317 | GCC_DYNAMIC_NO_PIC = NO; 318 | GCC_NO_COMMON_BLOCKS = YES; 319 | GCC_OPTIMIZATION_LEVEL = 0; 320 | GCC_PREPROCESSOR_DEFINITIONS = ( 321 | "DEBUG=1", 322 | "$(inherited)", 323 | ); 324 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 325 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 326 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 327 | GCC_WARN_UNDECLARED_SELECTOR = YES; 328 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 329 | GCC_WARN_UNUSED_FUNCTION = YES; 330 | GCC_WARN_UNUSED_VARIABLE = YES; 331 | IPHONEOS_DEPLOYMENT_TARGET = 8.3; 332 | MTL_ENABLE_DEBUG_INFO = YES; 333 | ONLY_ACTIVE_ARCH = YES; 334 | SDKROOT = iphoneos; 335 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 336 | }; 337 | name = Debug; 338 | }; 339 | 607FACEE1AFB9204008FA782 /* Release */ = { 340 | isa = XCBuildConfiguration; 341 | buildSettings = { 342 | ALWAYS_SEARCH_USER_PATHS = NO; 343 | CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; 344 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 345 | CLANG_CXX_LIBRARY = "libc++"; 346 | CLANG_ENABLE_MODULES = YES; 347 | CLANG_ENABLE_OBJC_ARC = YES; 348 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 349 | CLANG_WARN_BOOL_CONVERSION = YES; 350 | CLANG_WARN_COMMA = YES; 351 | CLANG_WARN_CONSTANT_CONVERSION = YES; 352 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 353 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 354 | CLANG_WARN_EMPTY_BODY = YES; 355 | CLANG_WARN_ENUM_CONVERSION = YES; 356 | CLANG_WARN_INFINITE_RECURSION = YES; 357 | CLANG_WARN_INT_CONVERSION = YES; 358 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 359 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 360 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 361 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 362 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 363 | CLANG_WARN_STRICT_PROTOTYPES = YES; 364 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 365 | CLANG_WARN_UNREACHABLE_CODE = YES; 366 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 367 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 368 | COPY_PHASE_STRIP = NO; 369 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 370 | ENABLE_NS_ASSERTIONS = NO; 371 | ENABLE_STRICT_OBJC_MSGSEND = YES; 372 | GCC_C_LANGUAGE_STANDARD = gnu99; 373 | GCC_NO_COMMON_BLOCKS = YES; 374 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 375 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 376 | GCC_WARN_UNDECLARED_SELECTOR = YES; 377 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 378 | GCC_WARN_UNUSED_FUNCTION = YES; 379 | GCC_WARN_UNUSED_VARIABLE = YES; 380 | IPHONEOS_DEPLOYMENT_TARGET = 8.3; 381 | MTL_ENABLE_DEBUG_INFO = NO; 382 | SDKROOT = iphoneos; 383 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 384 | VALIDATE_PRODUCT = YES; 385 | }; 386 | name = Release; 387 | }; 388 | 607FACF01AFB9204008FA782 /* Debug */ = { 389 | isa = XCBuildConfiguration; 390 | baseConfigurationReference = 2A4940A6A8A5E9483952ADD0 /* Pods-AACoreData_Example.debug.xcconfig */; 391 | buildSettings = { 392 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 393 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 394 | DEVELOPMENT_TEAM = 5J29YQGG4K; 395 | INFOPLIST_FILE = AACoreData/Info.plist; 396 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 397 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 398 | MODULE_NAME = ExampleApp; 399 | MOMC_NO_DELETE_RULE_WARNINGS = YES; 400 | MOMC_NO_INVERSE_RELATIONSHIP_WARNINGS = NO; 401 | PRODUCT_BUNDLE_IDENTIFIER = com.aacreations.coredata; 402 | PRODUCT_NAME = "$(TARGET_NAME)"; 403 | SWIFT_SWIFT3_OBJC_INFERENCE = On; 404 | SWIFT_VERSION = 4.0; 405 | }; 406 | name = Debug; 407 | }; 408 | 607FACF11AFB9204008FA782 /* Release */ = { 409 | isa = XCBuildConfiguration; 410 | baseConfigurationReference = A5527CFE0CA65E29D3B457B8 /* Pods-AACoreData_Example.release.xcconfig */; 411 | buildSettings = { 412 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 413 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 414 | DEVELOPMENT_TEAM = 5J29YQGG4K; 415 | INFOPLIST_FILE = AACoreData/Info.plist; 416 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 417 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 418 | MODULE_NAME = ExampleApp; 419 | MOMC_NO_DELETE_RULE_WARNINGS = YES; 420 | MOMC_NO_INVERSE_RELATIONSHIP_WARNINGS = NO; 421 | PRODUCT_BUNDLE_IDENTIFIER = com.aacreations.coredata; 422 | PRODUCT_NAME = "$(TARGET_NAME)"; 423 | SWIFT_SWIFT3_OBJC_INFERENCE = On; 424 | SWIFT_VERSION = 4.0; 425 | }; 426 | name = Release; 427 | }; 428 | /* End XCBuildConfiguration section */ 429 | 430 | /* Begin XCConfigurationList section */ 431 | 607FACCB1AFB9204008FA782 /* Build configuration list for PBXProject "AACoreData" */ = { 432 | isa = XCConfigurationList; 433 | buildConfigurations = ( 434 | 607FACED1AFB9204008FA782 /* Debug */, 435 | 607FACEE1AFB9204008FA782 /* Release */, 436 | ); 437 | defaultConfigurationIsVisible = 0; 438 | defaultConfigurationName = Release; 439 | }; 440 | 607FACEF1AFB9204008FA782 /* Build configuration list for PBXNativeTarget "AACoreData_Example" */ = { 441 | isa = XCConfigurationList; 442 | buildConfigurations = ( 443 | 607FACF01AFB9204008FA782 /* Debug */, 444 | 607FACF11AFB9204008FA782 /* Release */, 445 | ); 446 | defaultConfigurationIsVisible = 0; 447 | defaultConfigurationName = Release; 448 | }; 449 | /* End XCConfigurationList section */ 450 | 451 | /* Begin XCVersionGroup section */ 452 | 424077021E12A74400A7141E /* ExampleDataModel.xcdatamodeld */ = { 453 | isa = XCVersionGroup; 454 | children = ( 455 | 424077031E12A74400A7141E /* ExampleDataModel.xcdatamodel */, 456 | ); 457 | currentVersion = 424077031E12A74400A7141E /* ExampleDataModel.xcdatamodel */; 458 | path = ExampleDataModel.xcdatamodeld; 459 | sourceTree = ""; 460 | versionGroupType = wrapper.xcdatamodel; 461 | }; 462 | /* End XCVersionGroup section */ 463 | }; 464 | rootObject = 607FACC81AFB9204008FA782 /* Project object */; 465 | } 466 | -------------------------------------------------------------------------------- /Example/AACoreData.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /Example/AACoreData.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /Example/AACoreData.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Example/AACoreData.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Example/AACoreData/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.swift 3 | // AACoreData 4 | // 5 | // Created by Engr. Ahsan Ali on 12/27/2016. 6 | // Copyright (c) 2016 AA-Creations. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | import AACoreData 11 | 12 | @UIApplicationMain 13 | class AppDelegate: UIResponder, UIApplicationDelegate { 14 | 15 | var window: UIWindow? 16 | 17 | 18 | 19 | func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { 20 | // Override point for customization after application launch. 21 | 22 | AACoreData.shared.dataModel = "ExampleDataModel" 23 | 24 | return true 25 | } 26 | 27 | 28 | func applicationWillResignActive(_ application: UIApplication) { 29 | // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. 30 | // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. 31 | } 32 | 33 | func applicationDidEnterBackground(_ application: UIApplication) { 34 | // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. 35 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. 36 | } 37 | 38 | func applicationWillEnterForeground(_ application: UIApplication) { 39 | // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. 40 | } 41 | 42 | func applicationDidBecomeActive(_ application: UIApplication) { 43 | // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. 44 | } 45 | 46 | func applicationWillTerminate(_ application: UIApplication) { 47 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. 48 | } 49 | 50 | 51 | } 52 | 53 | -------------------------------------------------------------------------------- /Example/AACoreData/Base.lproj/LaunchScreen.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 27 | 28 | 29 | 30 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | -------------------------------------------------------------------------------- /Example/AACoreData/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 36 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | -------------------------------------------------------------------------------- /Example/AACoreData/Constants.swift: -------------------------------------------------------------------------------- 1 | // 2 | // Constants.swift 3 | // AACoreData 4 | // 5 | // Created by Engr. Ahsan Ali on 27/12/2016. 6 | // Copyright © 2016 AA-Creations. All rights reserved. 7 | // 8 | 9 | import Foundation 10 | import AACoreData 11 | 12 | 13 | extension AACoreData { 14 | 15 | // MARK:- Add your entities here 16 | 17 | static let Example = AACoreEntity("ExampleEntity") 18 | 19 | 20 | } 21 | -------------------------------------------------------------------------------- /Example/AACoreData/ExampleDataModel.xcdatamodeld/ExampleDataModel.xcdatamodel/contents: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AA.imageset/17049477.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AA.imageset/17049477.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AA.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "17049477.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | } 21 | } -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "20x20", 5 | "idiom" : "iphone", 6 | "filename" : "Icon-App-20x20@2x.png", 7 | "scale" : "2x" 8 | }, 9 | { 10 | "size" : "20x20", 11 | "idiom" : "iphone", 12 | "filename" : "Icon-App-20x20@3x.png", 13 | "scale" : "3x" 14 | }, 15 | { 16 | "size" : "29x29", 17 | "idiom" : "iphone", 18 | "filename" : "Icon-App-29x29@1x.png", 19 | "scale" : "1x" 20 | }, 21 | { 22 | "size" : "29x29", 23 | "idiom" : "iphone", 24 | "filename" : "Icon-App-29x29@2x.png", 25 | "scale" : "2x" 26 | }, 27 | { 28 | "size" : "29x29", 29 | "idiom" : "iphone", 30 | "filename" : "Icon-App-29x29@3x.png", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "size" : "40x40", 35 | "idiom" : "iphone", 36 | "filename" : "Icon-App-40x40@2x.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "size" : "40x40", 41 | "idiom" : "iphone", 42 | "filename" : "Icon-App-40x40@3x.png", 43 | "scale" : "3x" 44 | }, 45 | { 46 | "size" : "57x57", 47 | "idiom" : "iphone", 48 | "filename" : "Icon-App-57x57@1x.png", 49 | "scale" : "1x" 50 | }, 51 | { 52 | "size" : "57x57", 53 | "idiom" : "iphone", 54 | "filename" : "Icon-App-57x57@2x.png", 55 | "scale" : "2x" 56 | }, 57 | { 58 | "size" : "60x60", 59 | "idiom" : "iphone", 60 | "filename" : "Icon-App-60x60@2x.png", 61 | "scale" : "2x" 62 | }, 63 | { 64 | "size" : "60x60", 65 | "idiom" : "iphone", 66 | "filename" : "Icon-App-60x60@3x.png", 67 | "scale" : "3x" 68 | }, 69 | { 70 | "size" : "20x20", 71 | "idiom" : "ipad", 72 | "filename" : "Icon-App-20x20@1x.png", 73 | "scale" : "1x" 74 | }, 75 | { 76 | "size" : "20x20", 77 | "idiom" : "ipad", 78 | "filename" : "Icon-App-20x20@2x.png", 79 | "scale" : "2x" 80 | }, 81 | { 82 | "size" : "29x29", 83 | "idiom" : "ipad", 84 | "filename" : "Icon-App-29x29@1x.png", 85 | "scale" : "1x" 86 | }, 87 | { 88 | "size" : "29x29", 89 | "idiom" : "ipad", 90 | "filename" : "Icon-App-29x29@2x.png", 91 | "scale" : "2x" 92 | }, 93 | { 94 | "size" : "40x40", 95 | "idiom" : "ipad", 96 | "filename" : "Icon-App-40x40@1x.png", 97 | "scale" : "1x" 98 | }, 99 | { 100 | "size" : "40x40", 101 | "idiom" : "ipad", 102 | "filename" : "Icon-App-40x40@2x.png", 103 | "scale" : "2x" 104 | }, 105 | { 106 | "size" : "50x50", 107 | "idiom" : "ipad", 108 | "filename" : "Icon-Small-50x50@1x.png", 109 | "scale" : "1x" 110 | }, 111 | { 112 | "size" : "50x50", 113 | "idiom" : "ipad", 114 | "filename" : "Icon-Small-50x50@2x.png", 115 | "scale" : "2x" 116 | }, 117 | { 118 | "size" : "72x72", 119 | "idiom" : "ipad", 120 | "filename" : "Icon-App-72x72@1x.png", 121 | "scale" : "1x" 122 | }, 123 | { 124 | "size" : "72x72", 125 | "idiom" : "ipad", 126 | "filename" : "Icon-App-72x72@2x.png", 127 | "scale" : "2x" 128 | }, 129 | { 130 | "size" : "76x76", 131 | "idiom" : "ipad", 132 | "filename" : "Icon-App-76x76@1x.png", 133 | "scale" : "1x" 134 | }, 135 | { 136 | "size" : "76x76", 137 | "idiom" : "ipad", 138 | "filename" : "Icon-App-76x76@2x.png", 139 | "scale" : "2x" 140 | }, 141 | { 142 | "size" : "83.5x83.5", 143 | "idiom" : "ipad", 144 | "filename" : "Icon-App-83.5x83.5@2x.png", 145 | "scale" : "2x" 146 | } 147 | ], 148 | "info" : { 149 | "version" : 1, 150 | "author" : "xcode" 151 | } 152 | } -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-57x57@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-57x57@1x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-57x57@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-57x57@2x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-72x72@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-72x72@1x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-72x72@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-72x72@2x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-Small-50x50@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-Small-50x50@1x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-Small-50x50@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Example/AACoreData/Images.xcassets/AppIcon.appiconset/Icon-Small-50x50@2x.png -------------------------------------------------------------------------------- /Example/AACoreData/Images.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } -------------------------------------------------------------------------------- /Example/AACoreData/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | LSRequiresIPhoneOS 24 | 25 | UILaunchStoryboardName 26 | LaunchScreen 27 | UIMainStoryboardFile 28 | Main 29 | UIRequiredDeviceCapabilities 30 | 31 | armv7 32 | 33 | UISupportedInterfaceOrientations 34 | 35 | UIInterfaceOrientationPortrait 36 | UIInterfaceOrientationLandscapeLeft 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /Example/AACoreData/TableViewController.swift: -------------------------------------------------------------------------------- 1 | // 2 | // TableViewController.swift 3 | // AACoreData 4 | // 5 | // Created by Engr. Ahsan Ali on 27/12/2016. 6 | // Copyright © 2016 AA-Creations. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | import AACoreData 11 | 12 | class TableViewController: UITableViewController { 13 | 14 | 15 | let instance = AACoreData.shared 16 | 17 | var itemCounter: Int = 0 18 | 19 | var records: [ExampleEntity] = [ExampleEntity]() 20 | 21 | override func viewDidLoad() { 22 | super.viewDidLoad() 23 | 24 | self.navigationItem.leftBarButtonItem = self.editButtonItem 25 | self.tableView.allowsSelectionDuringEditing = true 26 | 27 | fetchRecords() 28 | 29 | } 30 | 31 | func fetchRecords() { 32 | let sorter = NSSortDescriptor(key: "name" , ascending: true) 33 | 34 | 35 | instance.fetchRecords(entityName: .Example, sortDescriptors: [sorter]) { (results) in 36 | if let result = results as? [ExampleEntity] { 37 | self.records = result 38 | self.tableView.reloadData() 39 | } 40 | else { 41 | print("AACoreData - NO RECORDS FOUND") 42 | } 43 | } 44 | 45 | 46 | 47 | } 48 | 49 | override func didReceiveMemoryWarning() { 50 | super.didReceiveMemoryWarning() 51 | // Dispose of any resources that can be recreated. 52 | } 53 | 54 | // MARK: - Table view data source 55 | 56 | override func numberOfSections(in tableView: UITableView) -> Int { 57 | return 1 58 | } 59 | 60 | override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { 61 | return records.count 62 | } 63 | 64 | override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { 65 | let cell: UITableViewCell = UITableViewCell(style: .subtitle, reuseIdentifier: "Cell") 66 | 67 | let entity = records[indexPath.row] 68 | cell.textLabel?.text = entity.name! 69 | cell.detailTextLabel?.text = entity.address! 70 | 71 | return cell 72 | 73 | } 74 | 75 | override func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) { 76 | let counter = indexPath.row + 1 77 | let record = records[indexPath.row] 78 | record.name = "Updated Name \(counter)" 79 | record.address = "Updated Address \(counter)" 80 | instance.saveContext() 81 | tableView.deselectRow(at: indexPath, animated: true) 82 | tableView.reloadRows(at: [indexPath], with: .fade) 83 | print("AACoreData - Updated!") 84 | 85 | } 86 | 87 | // Override to support conditional editing of the table view. 88 | override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { 89 | return true 90 | } 91 | 92 | // Override to support editing the table view. 93 | override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { 94 | if editingStyle == .delete { 95 | 96 | let record = records[indexPath.row] 97 | instance.deleteRecord(record) 98 | records.remove(at: indexPath.row) 99 | instance.saveContext() 100 | tableView.beginUpdates() 101 | tableView.deleteRows(at: [indexPath], with: .right) 102 | tableView.endUpdates() 103 | print("AACoreData - Deleted!") 104 | } 105 | } 106 | 107 | @IBAction func eraseAction(_ sender: Any) { 108 | 109 | instance.deleteAllRecords(entity: .Example) 110 | records.removeAll() 111 | tableView.reloadData() 112 | 113 | 114 | } 115 | @IBAction func addAction(_ sender: Any) { 116 | 117 | let counter = records.count + 1 118 | 119 | let record = instance.getNewObject(entityName: .Example) as! ExampleEntity 120 | record.name = "Demo Name: \(counter)" 121 | record.address = "Demo Address: \(counter)" 122 | records.append(record) 123 | instance.saveContext() 124 | 125 | let indexPath = IndexPath(row: records.count-1, section: 0) 126 | 127 | tableView.beginUpdates() 128 | tableView.insertRows(at: [indexPath], with: .left) 129 | tableView.endUpdates() 130 | print("AACoreData - Inserted!") 131 | 132 | } 133 | } 134 | -------------------------------------------------------------------------------- /Example/Podfile: -------------------------------------------------------------------------------- 1 | use_frameworks! 2 | 3 | target 'AACoreData_Example' do 4 | pod 'AACoreData', :path => '../' 5 | 6 | 7 | end 8 | -------------------------------------------------------------------------------- /Example/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - AACoreData (1.0.1) 3 | 4 | DEPENDENCIES: 5 | - AACoreData (from `../`) 6 | 7 | EXTERNAL SOURCES: 8 | AACoreData: 9 | :path: ../ 10 | 11 | SPEC CHECKSUMS: 12 | AACoreData: 5e978eb9c0b3bea1bb093258269676f29b08417c 13 | 14 | PODFILE CHECKSUM: 5c1d21595c9e1dadccec5671fcf73a814b2efbbf 15 | 16 | COCOAPODS: 1.2.0 17 | -------------------------------------------------------------------------------- /Example/Pods/Local Podspecs/AACoreData.podspec.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "AACoreData", 3 | "version": "1.0.1", 4 | "summary": "AACoreData is a lightweight data persistence wrapper designed to provide an easier solution for `CRUD` operations using CoreData in Swift.", 5 | "description": "AACoreData is a lightweight data persistence wrapper designed to provide an easier solution for `CRUD` operations using `CoreData`, written in Swift. It provides a singleton instance to access `CoreData` objects anywhere in the code and uses 'value types' to define `CoreData` entities.", 6 | "homepage": "https://github.com/EngrAhsanAli/AACoreData", 7 | "license": { 8 | "type": "MIT", 9 | "file": "LICENSE" 10 | }, 11 | "authors": { 12 | "Engr. Ahsan Ali": "hafiz.m.ahsan.ali@gmail.com" 13 | }, 14 | "source": { 15 | "git": "https://github.com/EngrAhsanAli/AACoreData.git", 16 | "tag": "1.0.1" 17 | }, 18 | "pod_target_xcconfig": { 19 | "SWIFT_VERSION": "3.0" 20 | }, 21 | "platforms": { 22 | "ios": "8.0" 23 | }, 24 | "source_files": "AACoreData/Classes/**/*" 25 | } 26 | -------------------------------------------------------------------------------- /Example/Pods/Manifest.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - AACoreData (1.0.1) 3 | 4 | DEPENDENCIES: 5 | - AACoreData (from `../`) 6 | 7 | EXTERNAL SOURCES: 8 | AACoreData: 9 | :path: ../ 10 | 11 | SPEC CHECKSUMS: 12 | AACoreData: 5e978eb9c0b3bea1bb093258269676f29b08417c 13 | 14 | PODFILE CHECKSUM: 5c1d21595c9e1dadccec5671fcf73a814b2efbbf 15 | 16 | COCOAPODS: 1.2.0 17 | -------------------------------------------------------------------------------- /Example/Pods/Pods.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 1A86CBB0F0902DD70545E6D0DD1F9DA1 /* AACoreData.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0625B065F22C0657D50254E5C126825F /* AACoreData.swift */; }; 11 | 22CC4FED05B6ABB26E7AB50079D314A9 /* AACoreData-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = 77F9648DCE598C7824BF8220881931F2 /* AACoreData-dummy.m */; }; 12 | 3580A4A6251F4609608A9344ADA3343A /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = CBB3DE36805AF21409EC968A9691732F /* Foundation.framework */; }; 13 | 524E7CF3215528F8003A0564 /* AACoreData+Helper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 524E7CF2215528F8003A0564 /* AACoreData+Helper.swift */; }; 14 | 8AD7A782C6A01E4A976F59CA50F98E49 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = CBB3DE36805AF21409EC968A9691732F /* Foundation.framework */; }; 15 | 9809ECE1EEE96D8A54D81389BCC3595F /* Pods-AACoreData_Example-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = 72D789D0119D37EA7F2302B0B07EBBB1 /* Pods-AACoreData_Example-dummy.m */; }; 16 | CBB3536EC322155056D3A92F09A364D0 /* AACoreData-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = BF521482B89C427E0C2737A363F57067 /* AACoreData-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; 17 | ED6FC965EC40C52555C9CBA77F0AD354 /* Pods-AACoreData_Example-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = 1CC233FF2AA5AA252B3385F9304838E8 /* Pods-AACoreData_Example-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; 18 | /* End PBXBuildFile section */ 19 | 20 | /* Begin PBXContainerItemProxy section */ 21 | E3BBB6AAE698F4E80DA365465A199E8D /* PBXContainerItemProxy */ = { 22 | isa = PBXContainerItemProxy; 23 | containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */; 24 | proxyType = 1; 25 | remoteGlobalIDString = B7EA03B748446B749E9B8EBF722F292D; 26 | remoteInfo = AACoreData; 27 | }; 28 | /* End PBXContainerItemProxy section */ 29 | 30 | /* Begin PBXFileReference section */ 31 | 0625B065F22C0657D50254E5C126825F /* AACoreData.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; path = AACoreData.swift; sourceTree = ""; }; 32 | 1CC233FF2AA5AA252B3385F9304838E8 /* Pods-AACoreData_Example-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Pods-AACoreData_Example-umbrella.h"; sourceTree = ""; }; 33 | 28AAF4710B2577A6827B6971436C61FC /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 34 | 2FEDC7A43CFDF2C253B05B880AD82468 /* AACoreData-prefix.pch */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "AACoreData-prefix.pch"; sourceTree = ""; }; 35 | 360B2F1C301793499E19FA202F024D9E /* Pods-AACoreData_Example.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-AACoreData_Example.debug.xcconfig"; sourceTree = ""; }; 36 | 524E7CF2215528F8003A0564 /* AACoreData+Helper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "AACoreData+Helper.swift"; sourceTree = ""; }; 37 | 590B210DAB029D1D2A8A26641EEA585A /* Pods-AACoreData_Example-acknowledgements.markdown */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; path = "Pods-AACoreData_Example-acknowledgements.markdown"; sourceTree = ""; }; 38 | 5A59B1E68E91878F7B8D02BC7CFB8F7A /* Pods_AACoreData_Example.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_AACoreData_Example.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 39 | 66579188FC2747BE1977F527ECCDB8AE /* AACoreData.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = AACoreData.xcconfig; sourceTree = ""; }; 40 | 72D789D0119D37EA7F2302B0B07EBBB1 /* Pods-AACoreData_Example-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Pods-AACoreData_Example-dummy.m"; sourceTree = ""; }; 41 | 77F9648DCE598C7824BF8220881931F2 /* AACoreData-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "AACoreData-dummy.m"; sourceTree = ""; }; 42 | 7B483B6F0B533339D49C74F63C7EBEE1 /* Pods-AACoreData_Example-frameworks.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-AACoreData_Example-frameworks.sh"; sourceTree = ""; }; 43 | 93A4A3777CF96A4AAC1D13BA6DCCEA73 /* Podfile */ = {isa = PBXFileReference; explicitFileType = text.script.ruby; includeInIndex = 1; name = Podfile; path = ../Podfile; sourceTree = SOURCE_ROOT; xcLanguageSpecificationIdentifier = xcode.lang.ruby; }; 44 | A02D698793424C63283955F37C3FA47A /* Pods-AACoreData_Example-resources.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-AACoreData_Example-resources.sh"; sourceTree = ""; }; 45 | AA891C0CE2B7A6BA1FC4310113EC626F /* AACoreData.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = AACoreData.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 46 | BB42ED507CD8AEDDA164ABC7D7389E61 /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 47 | BF521482B89C427E0C2737A363F57067 /* AACoreData-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "AACoreData-umbrella.h"; sourceTree = ""; }; 48 | CB0400C81CFE3B14CF9E709A2AFAF2CB /* Pods-AACoreData_Example.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-AACoreData_Example.release.xcconfig"; sourceTree = ""; }; 49 | CBB3DE36805AF21409EC968A9691732F /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS10.0.sdk/System/Library/Frameworks/Foundation.framework; sourceTree = DEVELOPER_DIR; }; 50 | CF1A05089E110D6804B189283A1AC87F /* Pods-AACoreData_Example.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; path = "Pods-AACoreData_Example.modulemap"; sourceTree = ""; }; 51 | D8DD6B70CC2C8845A5812778D8EECE1A /* Pods-AACoreData_Example-acknowledgements.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = "Pods-AACoreData_Example-acknowledgements.plist"; sourceTree = ""; }; 52 | FB8A21B02E323BC4AD70FB2B9039BDD0 /* AACoreData.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; path = AACoreData.modulemap; sourceTree = ""; }; 53 | /* End PBXFileReference section */ 54 | 55 | /* Begin PBXFrameworksBuildPhase section */ 56 | 471B4582028C4CBF85F9D923C59DD8CD /* Frameworks */ = { 57 | isa = PBXFrameworksBuildPhase; 58 | buildActionMask = 2147483647; 59 | files = ( 60 | 3580A4A6251F4609608A9344ADA3343A /* Foundation.framework in Frameworks */, 61 | ); 62 | runOnlyForDeploymentPostprocessing = 0; 63 | }; 64 | BF88518B6D299C71BA0D9CFD64DF8FF2 /* Frameworks */ = { 65 | isa = PBXFrameworksBuildPhase; 66 | buildActionMask = 2147483647; 67 | files = ( 68 | 8AD7A782C6A01E4A976F59CA50F98E49 /* Foundation.framework in Frameworks */, 69 | ); 70 | runOnlyForDeploymentPostprocessing = 0; 71 | }; 72 | /* End PBXFrameworksBuildPhase section */ 73 | 74 | /* Begin PBXGroup section */ 75 | 1F9477DE95089DB93FA15922EF3684A9 /* Development Pods */ = { 76 | isa = PBXGroup; 77 | children = ( 78 | B6CEEE158E0F1A8EDB5789CF147EF3D5 /* AACoreData */, 79 | ); 80 | name = "Development Pods"; 81 | sourceTree = ""; 82 | }; 83 | 4420EF7720B29A9E5BF2E549C31FC51C /* Pods-AACoreData_Example */ = { 84 | isa = PBXGroup; 85 | children = ( 86 | BB42ED507CD8AEDDA164ABC7D7389E61 /* Info.plist */, 87 | CF1A05089E110D6804B189283A1AC87F /* Pods-AACoreData_Example.modulemap */, 88 | 590B210DAB029D1D2A8A26641EEA585A /* Pods-AACoreData_Example-acknowledgements.markdown */, 89 | D8DD6B70CC2C8845A5812778D8EECE1A /* Pods-AACoreData_Example-acknowledgements.plist */, 90 | 72D789D0119D37EA7F2302B0B07EBBB1 /* Pods-AACoreData_Example-dummy.m */, 91 | 7B483B6F0B533339D49C74F63C7EBEE1 /* Pods-AACoreData_Example-frameworks.sh */, 92 | A02D698793424C63283955F37C3FA47A /* Pods-AACoreData_Example-resources.sh */, 93 | 1CC233FF2AA5AA252B3385F9304838E8 /* Pods-AACoreData_Example-umbrella.h */, 94 | 360B2F1C301793499E19FA202F024D9E /* Pods-AACoreData_Example.debug.xcconfig */, 95 | CB0400C81CFE3B14CF9E709A2AFAF2CB /* Pods-AACoreData_Example.release.xcconfig */, 96 | ); 97 | name = "Pods-AACoreData_Example"; 98 | path = "Target Support Files/Pods-AACoreData_Example"; 99 | sourceTree = ""; 100 | }; 101 | 522B85EE445C15EB13D7E07FEFA39287 /* Products */ = { 102 | isa = PBXGroup; 103 | children = ( 104 | AA891C0CE2B7A6BA1FC4310113EC626F /* AACoreData.framework */, 105 | 5A59B1E68E91878F7B8D02BC7CFB8F7A /* Pods_AACoreData_Example.framework */, 106 | ); 107 | name = Products; 108 | sourceTree = ""; 109 | }; 110 | 5FE10F780ABA056176D8E19168B0952B /* Targets Support Files */ = { 111 | isa = PBXGroup; 112 | children = ( 113 | 4420EF7720B29A9E5BF2E549C31FC51C /* Pods-AACoreData_Example */, 114 | ); 115 | name = "Targets Support Files"; 116 | sourceTree = ""; 117 | }; 118 | 62CCD53A60D4AA069EACED7B52717E6A /* AACoreData */ = { 119 | isa = PBXGroup; 120 | children = ( 121 | 6A4E80EC04BE4323B3579FDCCF3E5E41 /* Classes */, 122 | ); 123 | path = AACoreData; 124 | sourceTree = ""; 125 | }; 126 | 6A4E80EC04BE4323B3579FDCCF3E5E41 /* Classes */ = { 127 | isa = PBXGroup; 128 | children = ( 129 | 0625B065F22C0657D50254E5C126825F /* AACoreData.swift */, 130 | 524E7CF2215528F8003A0564 /* AACoreData+Helper.swift */, 131 | ); 132 | path = Classes; 133 | sourceTree = ""; 134 | }; 135 | 7531C8F8DE19F1AA3C8A7AC97A91DC29 /* iOS */ = { 136 | isa = PBXGroup; 137 | children = ( 138 | CBB3DE36805AF21409EC968A9691732F /* Foundation.framework */, 139 | ); 140 | name = iOS; 141 | sourceTree = ""; 142 | }; 143 | 7DB346D0F39D3F0E887471402A8071AB = { 144 | isa = PBXGroup; 145 | children = ( 146 | 93A4A3777CF96A4AAC1D13BA6DCCEA73 /* Podfile */, 147 | 1F9477DE95089DB93FA15922EF3684A9 /* Development Pods */, 148 | BC3CA7F9E30CC8F7E2DD044DD34432FC /* Frameworks */, 149 | 522B85EE445C15EB13D7E07FEFA39287 /* Products */, 150 | 5FE10F780ABA056176D8E19168B0952B /* Targets Support Files */, 151 | ); 152 | sourceTree = ""; 153 | }; 154 | A7DF52558BC48E0F8859EDB9F322D3D3 /* Support Files */ = { 155 | isa = PBXGroup; 156 | children = ( 157 | FB8A21B02E323BC4AD70FB2B9039BDD0 /* AACoreData.modulemap */, 158 | 66579188FC2747BE1977F527ECCDB8AE /* AACoreData.xcconfig */, 159 | 77F9648DCE598C7824BF8220881931F2 /* AACoreData-dummy.m */, 160 | 2FEDC7A43CFDF2C253B05B880AD82468 /* AACoreData-prefix.pch */, 161 | BF521482B89C427E0C2737A363F57067 /* AACoreData-umbrella.h */, 162 | 28AAF4710B2577A6827B6971436C61FC /* Info.plist */, 163 | ); 164 | name = "Support Files"; 165 | path = "Example/Pods/Target Support Files/AACoreData"; 166 | sourceTree = ""; 167 | }; 168 | B6CEEE158E0F1A8EDB5789CF147EF3D5 /* AACoreData */ = { 169 | isa = PBXGroup; 170 | children = ( 171 | 62CCD53A60D4AA069EACED7B52717E6A /* AACoreData */, 172 | A7DF52558BC48E0F8859EDB9F322D3D3 /* Support Files */, 173 | ); 174 | name = AACoreData; 175 | path = ../..; 176 | sourceTree = ""; 177 | }; 178 | BC3CA7F9E30CC8F7E2DD044DD34432FC /* Frameworks */ = { 179 | isa = PBXGroup; 180 | children = ( 181 | 7531C8F8DE19F1AA3C8A7AC97A91DC29 /* iOS */, 182 | ); 183 | name = Frameworks; 184 | sourceTree = ""; 185 | }; 186 | /* End PBXGroup section */ 187 | 188 | /* Begin PBXHeadersBuildPhase section */ 189 | 11C40C911AC31B9D55A5DC7F6F9B95CB /* Headers */ = { 190 | isa = PBXHeadersBuildPhase; 191 | buildActionMask = 2147483647; 192 | files = ( 193 | CBB3536EC322155056D3A92F09A364D0 /* AACoreData-umbrella.h in Headers */, 194 | ); 195 | runOnlyForDeploymentPostprocessing = 0; 196 | }; 197 | 56D333483F9C505BCEFCCF118F94298A /* Headers */ = { 198 | isa = PBXHeadersBuildPhase; 199 | buildActionMask = 2147483647; 200 | files = ( 201 | ED6FC965EC40C52555C9CBA77F0AD354 /* Pods-AACoreData_Example-umbrella.h in Headers */, 202 | ); 203 | runOnlyForDeploymentPostprocessing = 0; 204 | }; 205 | /* End PBXHeadersBuildPhase section */ 206 | 207 | /* Begin PBXNativeTarget section */ 208 | 21572BAB1A4CCD21FBEAC29062315D95 /* Pods-AACoreData_Example */ = { 209 | isa = PBXNativeTarget; 210 | buildConfigurationList = 59E00106FC88F05AB92635AB9005D503 /* Build configuration list for PBXNativeTarget "Pods-AACoreData_Example" */; 211 | buildPhases = ( 212 | 7465A00744D491F6FE32D2EBBA90CA17 /* Sources */, 213 | 471B4582028C4CBF85F9D923C59DD8CD /* Frameworks */, 214 | 56D333483F9C505BCEFCCF118F94298A /* Headers */, 215 | ); 216 | buildRules = ( 217 | ); 218 | dependencies = ( 219 | 6340C7E4BCAA69C2574227A82D37FB96 /* PBXTargetDependency */, 220 | ); 221 | name = "Pods-AACoreData_Example"; 222 | productName = "Pods-AACoreData_Example"; 223 | productReference = 5A59B1E68E91878F7B8D02BC7CFB8F7A /* Pods_AACoreData_Example.framework */; 224 | productType = "com.apple.product-type.framework"; 225 | }; 226 | B7EA03B748446B749E9B8EBF722F292D /* AACoreData */ = { 227 | isa = PBXNativeTarget; 228 | buildConfigurationList = E8E560DCCAE313513AE4E4CF1D0A7581 /* Build configuration list for PBXNativeTarget "AACoreData" */; 229 | buildPhases = ( 230 | 6E856F710E6F9D6E4385EFEB7439D566 /* Sources */, 231 | BF88518B6D299C71BA0D9CFD64DF8FF2 /* Frameworks */, 232 | 11C40C911AC31B9D55A5DC7F6F9B95CB /* Headers */, 233 | ); 234 | buildRules = ( 235 | ); 236 | dependencies = ( 237 | ); 238 | name = AACoreData; 239 | productName = AACoreData; 240 | productReference = AA891C0CE2B7A6BA1FC4310113EC626F /* AACoreData.framework */; 241 | productType = "com.apple.product-type.framework"; 242 | }; 243 | /* End PBXNativeTarget section */ 244 | 245 | /* Begin PBXProject section */ 246 | D41D8CD98F00B204E9800998ECF8427E /* Project object */ = { 247 | isa = PBXProject; 248 | attributes = { 249 | LastSwiftUpdateCheck = 0730; 250 | LastUpgradeCheck = 0940; 251 | TargetAttributes = { 252 | B7EA03B748446B749E9B8EBF722F292D = { 253 | LastSwiftMigration = 1020; 254 | }; 255 | }; 256 | }; 257 | buildConfigurationList = 2D8E8EC45A3A1A1D94AE762CB5028504 /* Build configuration list for PBXProject "Pods" */; 258 | compatibilityVersion = "Xcode 3.2"; 259 | developmentRegion = English; 260 | hasScannedForEncodings = 0; 261 | knownRegions = ( 262 | English, 263 | en, 264 | ); 265 | mainGroup = 7DB346D0F39D3F0E887471402A8071AB; 266 | productRefGroup = 522B85EE445C15EB13D7E07FEFA39287 /* Products */; 267 | projectDirPath = ""; 268 | projectRoot = ""; 269 | targets = ( 270 | B7EA03B748446B749E9B8EBF722F292D /* AACoreData */, 271 | 21572BAB1A4CCD21FBEAC29062315D95 /* Pods-AACoreData_Example */, 272 | ); 273 | }; 274 | /* End PBXProject section */ 275 | 276 | /* Begin PBXSourcesBuildPhase section */ 277 | 6E856F710E6F9D6E4385EFEB7439D566 /* Sources */ = { 278 | isa = PBXSourcesBuildPhase; 279 | buildActionMask = 2147483647; 280 | files = ( 281 | 524E7CF3215528F8003A0564 /* AACoreData+Helper.swift in Sources */, 282 | 22CC4FED05B6ABB26E7AB50079D314A9 /* AACoreData-dummy.m in Sources */, 283 | 1A86CBB0F0902DD70545E6D0DD1F9DA1 /* AACoreData.swift in Sources */, 284 | ); 285 | runOnlyForDeploymentPostprocessing = 0; 286 | }; 287 | 7465A00744D491F6FE32D2EBBA90CA17 /* Sources */ = { 288 | isa = PBXSourcesBuildPhase; 289 | buildActionMask = 2147483647; 290 | files = ( 291 | 9809ECE1EEE96D8A54D81389BCC3595F /* Pods-AACoreData_Example-dummy.m in Sources */, 292 | ); 293 | runOnlyForDeploymentPostprocessing = 0; 294 | }; 295 | /* End PBXSourcesBuildPhase section */ 296 | 297 | /* Begin PBXTargetDependency section */ 298 | 6340C7E4BCAA69C2574227A82D37FB96 /* PBXTargetDependency */ = { 299 | isa = PBXTargetDependency; 300 | name = AACoreData; 301 | target = B7EA03B748446B749E9B8EBF722F292D /* AACoreData */; 302 | targetProxy = E3BBB6AAE698F4E80DA365465A199E8D /* PBXContainerItemProxy */; 303 | }; 304 | /* End PBXTargetDependency section */ 305 | 306 | /* Begin XCBuildConfiguration section */ 307 | 015A368F878AC3E2CEAE21DDE8026304 /* Debug */ = { 308 | isa = XCBuildConfiguration; 309 | buildSettings = { 310 | ALWAYS_SEARCH_USER_PATHS = NO; 311 | CLANG_ANALYZER_NONNULL = YES; 312 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 313 | CLANG_CXX_LIBRARY = "libc++"; 314 | CLANG_ENABLE_MODULES = YES; 315 | CLANG_ENABLE_OBJC_ARC = YES; 316 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 317 | CLANG_WARN_BOOL_CONVERSION = YES; 318 | CLANG_WARN_COMMA = YES; 319 | CLANG_WARN_CONSTANT_CONVERSION = YES; 320 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 321 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES; 322 | CLANG_WARN_EMPTY_BODY = YES; 323 | CLANG_WARN_ENUM_CONVERSION = YES; 324 | CLANG_WARN_INFINITE_RECURSION = YES; 325 | CLANG_WARN_INT_CONVERSION = YES; 326 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 327 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 328 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 329 | CLANG_WARN_OBJC_ROOT_CLASS = YES; 330 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 331 | CLANG_WARN_STRICT_PROTOTYPES = YES; 332 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 333 | CLANG_WARN_UNREACHABLE_CODE = YES; 334 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 335 | CODE_SIGNING_REQUIRED = NO; 336 | COPY_PHASE_STRIP = NO; 337 | ENABLE_STRICT_OBJC_MSGSEND = YES; 338 | ENABLE_TESTABILITY = YES; 339 | GCC_C_LANGUAGE_STANDARD = gnu99; 340 | GCC_DYNAMIC_NO_PIC = NO; 341 | GCC_NO_COMMON_BLOCKS = YES; 342 | GCC_OPTIMIZATION_LEVEL = 0; 343 | GCC_PREPROCESSOR_DEFINITIONS = ( 344 | "POD_CONFIGURATION_DEBUG=1", 345 | "DEBUG=1", 346 | "$(inherited)", 347 | ); 348 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 349 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 350 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 351 | GCC_WARN_UNDECLARED_SELECTOR = YES; 352 | GCC_WARN_UNINITIALIZED_AUTOS = YES; 353 | GCC_WARN_UNUSED_FUNCTION = YES; 354 | GCC_WARN_UNUSED_VARIABLE = YES; 355 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 356 | ONLY_ACTIVE_ARCH = YES; 357 | PROVISIONING_PROFILE_SPECIFIER = NO_SIGNING/; 358 | STRIP_INSTALLED_PRODUCT = NO; 359 | SYMROOT = "${SRCROOT}/../build"; 360 | }; 361 | name = Debug; 362 | }; 363 | 4354C604A412EC0086B2D6BDEB24AAFB /* Release */ = { 364 | isa = XCBuildConfiguration; 365 | baseConfigurationReference = CB0400C81CFE3B14CF9E709A2AFAF2CB /* Pods-AACoreData_Example.release.xcconfig */; 366 | buildSettings = { 367 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; 368 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 369 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; 370 | CURRENT_PROJECT_VERSION = 1; 371 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 372 | DEFINES_MODULE = YES; 373 | DYLIB_COMPATIBILITY_VERSION = 1; 374 | DYLIB_CURRENT_VERSION = 1; 375 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 376 | ENABLE_STRICT_OBJC_MSGSEND = YES; 377 | GCC_NO_COMMON_BLOCKS = YES; 378 | INFOPLIST_FILE = "Target Support Files/Pods-AACoreData_Example/Info.plist"; 379 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 380 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 381 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 382 | MACH_O_TYPE = staticlib; 383 | MODULEMAP_FILE = "Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example.modulemap"; 384 | MTL_ENABLE_DEBUG_INFO = NO; 385 | OTHER_LDFLAGS = ""; 386 | OTHER_LIBTOOLFLAGS = ""; 387 | PODS_ROOT = "$(SRCROOT)"; 388 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; 389 | PRODUCT_NAME = Pods_AACoreData_Example; 390 | SDKROOT = iphoneos; 391 | SKIP_INSTALL = YES; 392 | TARGETED_DEVICE_FAMILY = "1,2"; 393 | VERSIONING_SYSTEM = "apple-generic"; 394 | VERSION_INFO_PREFIX = ""; 395 | }; 396 | name = Release; 397 | }; 398 | 44CDBB6D11DE06DB64D6268622BDC47E /* Release */ = { 399 | isa = XCBuildConfiguration; 400 | buildSettings = { 401 | ALWAYS_SEARCH_USER_PATHS = NO; 402 | CLANG_ANALYZER_NONNULL = YES; 403 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 404 | CLANG_CXX_LIBRARY = "libc++"; 405 | CLANG_ENABLE_MODULES = YES; 406 | CLANG_ENABLE_OBJC_ARC = YES; 407 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 408 | CLANG_WARN_BOOL_CONVERSION = YES; 409 | CLANG_WARN_COMMA = YES; 410 | CLANG_WARN_CONSTANT_CONVERSION = YES; 411 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 412 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES; 413 | CLANG_WARN_EMPTY_BODY = YES; 414 | CLANG_WARN_ENUM_CONVERSION = YES; 415 | CLANG_WARN_INFINITE_RECURSION = YES; 416 | CLANG_WARN_INT_CONVERSION = YES; 417 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 418 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 419 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 420 | CLANG_WARN_OBJC_ROOT_CLASS = YES; 421 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 422 | CLANG_WARN_STRICT_PROTOTYPES = YES; 423 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 424 | CLANG_WARN_UNREACHABLE_CODE = YES; 425 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 426 | CODE_SIGNING_REQUIRED = NO; 427 | COPY_PHASE_STRIP = YES; 428 | ENABLE_NS_ASSERTIONS = NO; 429 | ENABLE_STRICT_OBJC_MSGSEND = YES; 430 | GCC_C_LANGUAGE_STANDARD = gnu99; 431 | GCC_NO_COMMON_BLOCKS = YES; 432 | GCC_PREPROCESSOR_DEFINITIONS = ( 433 | "POD_CONFIGURATION_RELEASE=1", 434 | "$(inherited)", 435 | ); 436 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 437 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 438 | GCC_WARN_UNDECLARED_SELECTOR = YES; 439 | GCC_WARN_UNINITIALIZED_AUTOS = YES; 440 | GCC_WARN_UNUSED_FUNCTION = YES; 441 | GCC_WARN_UNUSED_VARIABLE = YES; 442 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 443 | PROVISIONING_PROFILE_SPECIFIER = NO_SIGNING/; 444 | STRIP_INSTALLED_PRODUCT = NO; 445 | SWIFT_COMPILATION_MODE = wholemodule; 446 | SYMROOT = "${SRCROOT}/../build"; 447 | VALIDATE_PRODUCT = YES; 448 | }; 449 | name = Release; 450 | }; 451 | 4762C583B1ACD3D585BCE0B3663D96CF /* Debug */ = { 452 | isa = XCBuildConfiguration; 453 | baseConfigurationReference = 360B2F1C301793499E19FA202F024D9E /* Pods-AACoreData_Example.debug.xcconfig */; 454 | buildSettings = { 455 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; 456 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 457 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; 458 | CURRENT_PROJECT_VERSION = 1; 459 | DEBUG_INFORMATION_FORMAT = dwarf; 460 | DEFINES_MODULE = YES; 461 | DYLIB_COMPATIBILITY_VERSION = 1; 462 | DYLIB_CURRENT_VERSION = 1; 463 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 464 | ENABLE_STRICT_OBJC_MSGSEND = YES; 465 | GCC_NO_COMMON_BLOCKS = YES; 466 | INFOPLIST_FILE = "Target Support Files/Pods-AACoreData_Example/Info.plist"; 467 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 468 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 469 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 470 | MACH_O_TYPE = staticlib; 471 | MODULEMAP_FILE = "Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example.modulemap"; 472 | MTL_ENABLE_DEBUG_INFO = YES; 473 | OTHER_LDFLAGS = ""; 474 | OTHER_LIBTOOLFLAGS = ""; 475 | PODS_ROOT = "$(SRCROOT)"; 476 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; 477 | PRODUCT_NAME = Pods_AACoreData_Example; 478 | SDKROOT = iphoneos; 479 | SKIP_INSTALL = YES; 480 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 481 | TARGETED_DEVICE_FAMILY = "1,2"; 482 | VERSIONING_SYSTEM = "apple-generic"; 483 | VERSION_INFO_PREFIX = ""; 484 | }; 485 | name = Debug; 486 | }; 487 | 675CD0F49768E8ABF777054EBFC4D7C8 /* Debug */ = { 488 | isa = XCBuildConfiguration; 489 | baseConfigurationReference = 66579188FC2747BE1977F527ECCDB8AE /* AACoreData.xcconfig */; 490 | buildSettings = { 491 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; 492 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 493 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; 494 | CURRENT_PROJECT_VERSION = 1; 495 | DEBUG_INFORMATION_FORMAT = dwarf; 496 | DEFINES_MODULE = YES; 497 | DYLIB_COMPATIBILITY_VERSION = 1; 498 | DYLIB_CURRENT_VERSION = 1; 499 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 500 | ENABLE_STRICT_OBJC_MSGSEND = YES; 501 | GCC_NO_COMMON_BLOCKS = YES; 502 | GCC_PREFIX_HEADER = "Target Support Files/AACoreData/AACoreData-prefix.pch"; 503 | INFOPLIST_FILE = "Target Support Files/AACoreData/Info.plist"; 504 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 505 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 506 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 507 | MODULEMAP_FILE = "Target Support Files/AACoreData/AACoreData.modulemap"; 508 | MTL_ENABLE_DEBUG_INFO = YES; 509 | PRODUCT_NAME = AACoreData; 510 | SDKROOT = iphoneos; 511 | SKIP_INSTALL = YES; 512 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 513 | SWIFT_VERSION = 5.0; 514 | TARGETED_DEVICE_FAMILY = "1,2"; 515 | VERSIONING_SYSTEM = "apple-generic"; 516 | VERSION_INFO_PREFIX = ""; 517 | }; 518 | name = Debug; 519 | }; 520 | ABC07767EC419C573248BCBEDB80568C /* Release */ = { 521 | isa = XCBuildConfiguration; 522 | baseConfigurationReference = 66579188FC2747BE1977F527ECCDB8AE /* AACoreData.xcconfig */; 523 | buildSettings = { 524 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; 525 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 526 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; 527 | CURRENT_PROJECT_VERSION = 1; 528 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 529 | DEFINES_MODULE = YES; 530 | DYLIB_COMPATIBILITY_VERSION = 1; 531 | DYLIB_CURRENT_VERSION = 1; 532 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 533 | ENABLE_STRICT_OBJC_MSGSEND = YES; 534 | GCC_NO_COMMON_BLOCKS = YES; 535 | GCC_PREFIX_HEADER = "Target Support Files/AACoreData/AACoreData-prefix.pch"; 536 | INFOPLIST_FILE = "Target Support Files/AACoreData/Info.plist"; 537 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 538 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 539 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 540 | MODULEMAP_FILE = "Target Support Files/AACoreData/AACoreData.modulemap"; 541 | MTL_ENABLE_DEBUG_INFO = NO; 542 | PRODUCT_NAME = AACoreData; 543 | SDKROOT = iphoneos; 544 | SKIP_INSTALL = YES; 545 | SWIFT_VERSION = 5.0; 546 | TARGETED_DEVICE_FAMILY = "1,2"; 547 | VERSIONING_SYSTEM = "apple-generic"; 548 | VERSION_INFO_PREFIX = ""; 549 | }; 550 | name = Release; 551 | }; 552 | /* End XCBuildConfiguration section */ 553 | 554 | /* Begin XCConfigurationList section */ 555 | 2D8E8EC45A3A1A1D94AE762CB5028504 /* Build configuration list for PBXProject "Pods" */ = { 556 | isa = XCConfigurationList; 557 | buildConfigurations = ( 558 | 015A368F878AC3E2CEAE21DDE8026304 /* Debug */, 559 | 44CDBB6D11DE06DB64D6268622BDC47E /* Release */, 560 | ); 561 | defaultConfigurationIsVisible = 0; 562 | defaultConfigurationName = Release; 563 | }; 564 | 59E00106FC88F05AB92635AB9005D503 /* Build configuration list for PBXNativeTarget "Pods-AACoreData_Example" */ = { 565 | isa = XCConfigurationList; 566 | buildConfigurations = ( 567 | 4762C583B1ACD3D585BCE0B3663D96CF /* Debug */, 568 | 4354C604A412EC0086B2D6BDEB24AAFB /* Release */, 569 | ); 570 | defaultConfigurationIsVisible = 0; 571 | defaultConfigurationName = Release; 572 | }; 573 | E8E560DCCAE313513AE4E4CF1D0A7581 /* Build configuration list for PBXNativeTarget "AACoreData" */ = { 574 | isa = XCConfigurationList; 575 | buildConfigurations = ( 576 | 675CD0F49768E8ABF777054EBFC4D7C8 /* Debug */, 577 | ABC07767EC419C573248BCBEDB80568C /* Release */, 578 | ); 579 | defaultConfigurationIsVisible = 0; 580 | defaultConfigurationName = Release; 581 | }; 582 | /* End XCConfigurationList section */ 583 | }; 584 | rootObject = D41D8CD98F00B204E9800998ECF8427E /* Project object */; 585 | } 586 | -------------------------------------------------------------------------------- /Example/Pods/Pods.xcodeproj/xcshareddata/xcschemes/AACoreData.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 34 | 35 | 45 | 46 | 52 | 53 | 54 | 55 | 56 | 57 | 63 | 64 | 70 | 71 | 72 | 73 | 75 | 76 | 79 | 80 | 81 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/AACoreData/AACoreData-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_AACoreData : NSObject 3 | @end 4 | @implementation PodsDummy_AACoreData 5 | @end 6 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/AACoreData/AACoreData-prefix.pch: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/AACoreData/AACoreData-umbrella.h: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | 14 | FOUNDATION_EXPORT double AACoreDataVersionNumber; 15 | FOUNDATION_EXPORT const unsigned char AACoreDataVersionString[]; 16 | 17 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/AACoreData/AACoreData.modulemap: -------------------------------------------------------------------------------- 1 | framework module AACoreData { 2 | umbrella header "AACoreData-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/AACoreData/AACoreData.xcconfig: -------------------------------------------------------------------------------- 1 | CONFIGURATION_BUILD_DIR = $PODS_CONFIGURATION_BUILD_DIR/AACoreData 2 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 3 | HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Public" 4 | OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" 5 | PODS_BUILD_DIR = $BUILD_DIR 6 | PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 7 | PODS_ROOT = ${SRCROOT} 8 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/../.. 9 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 10 | SKIP_INSTALL = YES 11 | SWIFT_VERSION = 3.0 12 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/AACoreData/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | ${PRODUCT_BUNDLE_IDENTIFIER} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0.1 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-AACoreData_Example/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | ${PRODUCT_BUNDLE_IDENTIFIER} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example-acknowledgements.markdown: -------------------------------------------------------------------------------- 1 | # Acknowledgements 2 | This application makes use of the following third party libraries: 3 | 4 | ## AACoreData 5 | 6 | Copyright (c) 2016 Engr. Ahsan Ali 7 | 8 | Permission is hereby granted, free of charge, to any person obtaining a copy 9 | of this software and associated documentation files (the "Software"), to deal 10 | in the Software without restriction, including without limitation the rights 11 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 12 | copies of the Software, and to permit persons to whom the Software is 13 | furnished to do so, subject to the following conditions: 14 | 15 | The above copyright notice and this permission notice shall be included in 16 | all copies or substantial portions of the Software. 17 | 18 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 19 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 20 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 21 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 22 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 23 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 24 | THE SOFTWARE. 25 | 26 | Generated by CocoaPods - https://cocoapods.org 27 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example-acknowledgements.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreferenceSpecifiers 6 | 7 | 8 | FooterText 9 | This application makes use of the following third party libraries: 10 | Title 11 | Acknowledgements 12 | Type 13 | PSGroupSpecifier 14 | 15 | 16 | FooterText 17 | Copyright (c) 2016 Engr. Ahsan Ali <hafiz.m.ahsan.ali@gmail.com> 18 | 19 | Permission is hereby granted, free of charge, to any person obtaining a copy 20 | of this software and associated documentation files (the "Software"), to deal 21 | in the Software without restriction, including without limitation the rights 22 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 23 | copies of the Software, and to permit persons to whom the Software is 24 | furnished to do so, subject to the following conditions: 25 | 26 | The above copyright notice and this permission notice shall be included in 27 | all copies or substantial portions of the Software. 28 | 29 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 30 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 31 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 32 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 33 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 34 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 35 | THE SOFTWARE. 36 | 37 | License 38 | MIT 39 | Title 40 | AACoreData 41 | Type 42 | PSGroupSpecifier 43 | 44 | 45 | FooterText 46 | Generated by CocoaPods - https://cocoapods.org 47 | Title 48 | 49 | Type 50 | PSGroupSpecifier 51 | 52 | 53 | StringsTable 54 | Acknowledgements 55 | Title 56 | Acknowledgements 57 | 58 | 59 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_Pods_AACoreData_Example : NSObject 3 | @end 4 | @implementation PodsDummy_Pods_AACoreData_Example 5 | @end 6 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example-frameworks.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -e 3 | 4 | echo "mkdir -p ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 5 | mkdir -p "${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 6 | 7 | SWIFT_STDLIB_PATH="${DT_TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}" 8 | 9 | install_framework() 10 | { 11 | if [ -r "${BUILT_PRODUCTS_DIR}/$1" ]; then 12 | local source="${BUILT_PRODUCTS_DIR}/$1" 13 | elif [ -r "${BUILT_PRODUCTS_DIR}/$(basename "$1")" ]; then 14 | local source="${BUILT_PRODUCTS_DIR}/$(basename "$1")" 15 | elif [ -r "$1" ]; then 16 | local source="$1" 17 | fi 18 | 19 | local destination="${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 20 | 21 | if [ -L "${source}" ]; then 22 | echo "Symlinked..." 23 | source="$(readlink "${source}")" 24 | fi 25 | 26 | # use filter instead of exclude so missing patterns dont' throw errors 27 | echo "rsync -av --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${source}\" \"${destination}\"" 28 | rsync -av --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${source}" "${destination}" 29 | 30 | local basename 31 | basename="$(basename -s .framework "$1")" 32 | binary="${destination}/${basename}.framework/${basename}" 33 | if ! [ -r "$binary" ]; then 34 | binary="${destination}/${basename}" 35 | fi 36 | 37 | # Strip invalid architectures so "fat" simulator / device frameworks work on device 38 | if [[ "$(file "$binary")" == *"dynamically linked shared library"* ]]; then 39 | strip_invalid_archs "$binary" 40 | fi 41 | 42 | # Resign the code if required by the build settings to avoid unstable apps 43 | code_sign_if_enabled "${destination}/$(basename "$1")" 44 | 45 | # Embed linked Swift runtime libraries. No longer necessary as of Xcode 7. 46 | if [ "${XCODE_VERSION_MAJOR}" -lt 7 ]; then 47 | local swift_runtime_libs 48 | swift_runtime_libs=$(xcrun otool -LX "$binary" | grep --color=never @rpath/libswift | sed -E s/@rpath\\/\(.+dylib\).*/\\1/g | uniq -u && exit ${PIPESTATUS[0]}) 49 | for lib in $swift_runtime_libs; do 50 | echo "rsync -auv \"${SWIFT_STDLIB_PATH}/${lib}\" \"${destination}\"" 51 | rsync -auv "${SWIFT_STDLIB_PATH}/${lib}" "${destination}" 52 | code_sign_if_enabled "${destination}/${lib}" 53 | done 54 | fi 55 | } 56 | 57 | # Signs a framework with the provided identity 58 | code_sign_if_enabled() { 59 | if [ -n "${EXPANDED_CODE_SIGN_IDENTITY}" -a "${CODE_SIGNING_REQUIRED}" != "NO" -a "${CODE_SIGNING_ALLOWED}" != "NO" ]; then 60 | # Use the current code_sign_identitiy 61 | echo "Code Signing $1 with Identity ${EXPANDED_CODE_SIGN_IDENTITY_NAME}" 62 | local code_sign_cmd="/usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} ${OTHER_CODE_SIGN_FLAGS} --preserve-metadata=identifier,entitlements '$1'" 63 | 64 | if [ "${COCOAPODS_PARALLEL_CODE_SIGN}" == "true" ]; then 65 | code_sign_cmd="$code_sign_cmd &" 66 | fi 67 | echo "$code_sign_cmd" 68 | eval "$code_sign_cmd" 69 | fi 70 | } 71 | 72 | # Strip invalid architectures 73 | strip_invalid_archs() { 74 | binary="$1" 75 | # Get architectures for current file 76 | archs="$(lipo -info "$binary" | rev | cut -d ':' -f1 | rev)" 77 | stripped="" 78 | for arch in $archs; do 79 | if ! [[ "${VALID_ARCHS}" == *"$arch"* ]]; then 80 | # Strip non-valid architectures in-place 81 | lipo -remove "$arch" -output "$binary" "$binary" || exit 1 82 | stripped="$stripped $arch" 83 | fi 84 | done 85 | if [[ "$stripped" ]]; then 86 | echo "Stripped $binary of architectures:$stripped" 87 | fi 88 | } 89 | 90 | 91 | if [[ "$CONFIGURATION" == "Debug" ]]; then 92 | install_framework "$BUILT_PRODUCTS_DIR/AACoreData/AACoreData.framework" 93 | fi 94 | if [[ "$CONFIGURATION" == "Release" ]]; then 95 | install_framework "$BUILT_PRODUCTS_DIR/AACoreData/AACoreData.framework" 96 | fi 97 | if [ "${COCOAPODS_PARALLEL_CODE_SIGN}" == "true" ]; then 98 | wait 99 | fi 100 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example-resources.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -e 3 | 4 | mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 5 | 6 | RESOURCES_TO_COPY=${PODS_ROOT}/resources-to-copy-${TARGETNAME}.txt 7 | > "$RESOURCES_TO_COPY" 8 | 9 | XCASSET_FILES=() 10 | 11 | case "${TARGETED_DEVICE_FAMILY}" in 12 | 1,2) 13 | TARGET_DEVICE_ARGS="--target-device ipad --target-device iphone" 14 | ;; 15 | 1) 16 | TARGET_DEVICE_ARGS="--target-device iphone" 17 | ;; 18 | 2) 19 | TARGET_DEVICE_ARGS="--target-device ipad" 20 | ;; 21 | 3) 22 | TARGET_DEVICE_ARGS="--target-device tv" 23 | ;; 24 | *) 25 | TARGET_DEVICE_ARGS="--target-device mac" 26 | ;; 27 | esac 28 | 29 | install_resource() 30 | { 31 | if [[ "$1" = /* ]] ; then 32 | RESOURCE_PATH="$1" 33 | else 34 | RESOURCE_PATH="${PODS_ROOT}/$1" 35 | fi 36 | if [[ ! -e "$RESOURCE_PATH" ]] ; then 37 | cat << EOM 38 | error: Resource "$RESOURCE_PATH" not found. Run 'pod install' to update the copy resources script. 39 | EOM 40 | exit 1 41 | fi 42 | case $RESOURCE_PATH in 43 | *.storyboard) 44 | echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" 45 | ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS} 46 | ;; 47 | *.xib) 48 | echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" 49 | ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS} 50 | ;; 51 | *.framework) 52 | echo "mkdir -p ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 53 | mkdir -p "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 54 | echo "rsync -av $RESOURCE_PATH ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 55 | rsync -av "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 56 | ;; 57 | *.xcdatamodel) 58 | echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH"`.mom\"" 59 | xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodel`.mom" 60 | ;; 61 | *.xcdatamodeld) 62 | echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd\"" 63 | xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd" 64 | ;; 65 | *.xcmappingmodel) 66 | echo "xcrun mapc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm\"" 67 | xcrun mapc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm" 68 | ;; 69 | *.xcassets) 70 | ABSOLUTE_XCASSET_FILE="$RESOURCE_PATH" 71 | XCASSET_FILES+=("$ABSOLUTE_XCASSET_FILE") 72 | ;; 73 | *) 74 | echo "$RESOURCE_PATH" 75 | echo "$RESOURCE_PATH" >> "$RESOURCES_TO_COPY" 76 | ;; 77 | esac 78 | } 79 | 80 | mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 81 | rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 82 | if [[ "${ACTION}" == "install" ]] && [[ "${SKIP_INSTALL}" == "NO" ]]; then 83 | mkdir -p "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 84 | rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 85 | fi 86 | rm -f "$RESOURCES_TO_COPY" 87 | 88 | if [[ -n "${WRAPPER_EXTENSION}" ]] && [ "`xcrun --find actool`" ] && [ -n "$XCASSET_FILES" ] 89 | then 90 | # Find all other xcassets (this unfortunately includes those of path pods and other targets). 91 | OTHER_XCASSETS=$(find "$PWD" -iname "*.xcassets" -type d) 92 | while read line; do 93 | if [[ $line != "${PODS_ROOT}*" ]]; then 94 | XCASSET_FILES+=("$line") 95 | fi 96 | done <<<"$OTHER_XCASSETS" 97 | 98 | printf "%s\0" "${XCASSET_FILES[@]}" | xargs -0 xcrun actool --output-format human-readable-text --notices --warnings --platform "${PLATFORM_NAME}" --minimum-deployment-target "${!DEPLOYMENT_TARGET_SETTING_NAME}" ${TARGET_DEVICE_ARGS} --compress-pngs --compile "${BUILT_PRODUCTS_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 99 | fi 100 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example-umbrella.h: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | 14 | FOUNDATION_EXPORT double Pods_AACoreData_ExampleVersionNumber; 15 | FOUNDATION_EXPORT const unsigned char Pods_AACoreData_ExampleVersionString[]; 16 | 17 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example.debug.xcconfig: -------------------------------------------------------------------------------- 1 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/AACoreData" 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' 5 | OTHER_CFLAGS = $(inherited) -iquote "$PODS_CONFIGURATION_BUILD_DIR/AACoreData/AACoreData.framework/Headers" 6 | OTHER_LDFLAGS = $(inherited) -framework "AACoreData" 7 | OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" 8 | PODS_BUILD_DIR = $BUILD_DIR 9 | PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 10 | PODS_ROOT = ${SRCROOT}/Pods 11 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example.modulemap: -------------------------------------------------------------------------------- 1 | framework module Pods_AACoreData_Example { 2 | umbrella header "Pods-AACoreData_Example-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-AACoreData_Example/Pods-AACoreData_Example.release.xcconfig: -------------------------------------------------------------------------------- 1 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/AACoreData" 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' 5 | OTHER_CFLAGS = $(inherited) -iquote "$PODS_CONFIGURATION_BUILD_DIR/AACoreData/AACoreData.framework/Headers" 6 | OTHER_LDFLAGS = $(inherited) -framework "AACoreData" 7 | OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" 8 | PODS_BUILD_DIR = $BUILD_DIR 9 | PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 10 | PODS_ROOT = ${SRCROOT}/Pods 11 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2016 Engr. Ahsan Ali 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining a copy 4 | of this software and associated documentation files (the "Software"), to deal 5 | in the Software without restriction, including without limitation the rights 6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 | copies of the Software, and to permit persons to whom the Software is 8 | furnished to do so, subject to the following conditions: 9 | 10 | The above copyright notice and this permission notice shall be included in 11 | all copies or substantial portions of the Software. 12 | 13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 19 | THE SOFTWARE. 20 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Table of Contents 2 | 3 | - [AACoreData](#section-id-3) 4 | - [Description](#section-id-10) 5 | - [Demonstration](#section-id-15) 6 | - [Requirements](#section-id-24) 7 | - [Installation](#section-id-29) 8 | - [CocoaPods](#section-id-33) 9 | - [Carthage](#section-id-56) 10 | - [Manual Installation](#section-id-74) 11 | - [Getting Started](#section-id-87) 12 | - [Define entities](#section-id-83) 13 | - [Shared Instance](#section-id-92) 14 | - [Creating your own data model](#section-id-102) 15 | - [Create new entity object](#section-id-119) 16 | - [Save your changes](#section-id-128) 17 | - [Fetch your records](#section-id-138) 18 | - [Delete a object](#section-id-166) 19 | - [Delete all objects](#section-id-180) 20 | - [Contributions & License](#section-id-192) 21 | 22 | 23 | 24 |
25 | 26 | #AACoreData 27 | 28 | [![Swift 4.0](https://img.shields.io/badge/Swift-4.0-orange.svg?style=flat)](https://developer.apple.com/swift/) [![Carthage compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/Carthage/Carthage) [![CocoaPods](https://img.shields.io/cocoapods/v/AACoreData.svg)](http://cocoadocs.org/docsets/AACoreData) [![License MIT](https://img.shields.io/badge/License-MIT-blue.svg?style=flat)](https://github.com/Carthage/Carthage) [![Build Status](https://travis-ci.org/EngrAhsanAli/AACoreData.svg?branch=master)](https://travis-ci.org/EngrAhsanAli/AACoreData) 29 | ![License MIT](https://img.shields.io/github/license/mashape/apistatus.svg) [![CocoaPods](https://img.shields.io/cocoapods/p/AACoreData.svg)]() 30 | 31 | 32 |
33 | 34 | ##Description 35 | 36 | 37 | AACoreData is a lightweight data persistence wrapper designed to provide an easier solution for `CRUD` operations using `CoreData`, written in Swift. It provides a singleton instance to access `CoreData` objects anywhere in the code and uses 'value types' to define `CoreData` entities. 38 | 39 |
40 | 41 | ##Demonstration 42 | 43 | 44 | 45 | ![](https://github.com/EngrAhsanAli/AACoreData/blob/master/Screenshots/demo.gif) 46 | 47 | 48 | To run the example project, clone the repo, and run `pod install` from the Example directory first. 49 | 50 |
51 | 52 | ##Requirements 53 | 54 | - iOS 8.0+ / Mac OS X 10.9+ / tvOS 9.0+ / watchOS 2.0+ 55 | - Xcode 8.0+ 56 | 57 |
58 | 59 | # Installation 60 | 61 | AACoreData can be installed using CocoaPods, Carthage, or manually. 62 | 63 |
64 | 65 | ##CocoaPods 66 | 67 | AACoreData is available through [CocoaPods](http://cocoapods.org). To install CocoaPods, run: 68 | 69 | $ gem install cocoapods 70 | 71 | Then create a Podfile with the following contents: 72 | 73 | ``` 74 | source 'https://github.com/CocoaPods/Specs.git' 75 | platform :ios, '8.0' 76 | use_frameworks! 77 | 78 | target '' do 79 | pod 'AACoreData', '~> 1.0' 80 | end 81 | 82 | ``` 83 | 84 | Finally, run the following command to install it: 85 | ``` 86 | $ pod install 87 | ``` 88 | 89 |
90 | 91 | ##Carthage 92 | 93 | To install Carthage, run (using Homebrew): 94 | ``` 95 | $ brew update 96 | $ brew install carthage 97 | ``` 98 | Then add the following line to your Cartfile: 99 | 100 | ``` 101 | github "EngrAhsanAli/AACoreData" 102 | ``` 103 | 104 | Then import the library in all files where you use it: 105 | ```ruby 106 | import AACoreData 107 | ``` 108 | 109 |
110 | 111 | ##Manual Installation 112 | 113 | Simply copy `Classes/AACoreData.swift` to your Xcode project and that's it! 114 | 115 | 116 |
117 | 118 | #Getting Started 119 | ---------- 120 | 121 | 122 |
123 | 124 | ##Define entities 125 | 126 | ```ruby 127 | extension AACoreData { 128 | static let myEntity = AACoreEntity("ExampleEntity") 129 | } 130 | ``` 131 | 132 |
133 | 134 | ##Shared Instance 135 | 136 | You can access the instance easily by adding this line in specific class or globally anywhere outside the class: 137 | 138 | ```ruby 139 | let instance = AACoreData.shared 140 | ``` 141 | 142 | 143 |
144 | 145 | ##Creating your own data model 146 | 147 | You have to create your own data model file in your project. By default `"AACoreData.xcdatamodeld"` is assumed to find in your project bundle like `./YouAppName/AACoreData.xcdatamodeld` 148 | If you want to create different name of data model, then you have to specify it by using singleton property in `AppDelegate.swift` 149 | 150 | ```ruby 151 | func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { 152 | 153 | AACoreData.shared.dataModel = "ExampleDataModel" 154 | return true 155 | } 156 | ``` 157 | 158 | 159 | 160 |
161 | 162 | ##Create new entity object 163 | ```ruby 164 | let record = instance.getNewObject(entityName: .myEntity) as! ExampleEntity 165 | ``` 166 | 167 | 168 | 169 |
170 | 171 | ##Save your changes 172 | 173 | ``` 174 | instance.saveContext() 175 | ``` 176 | 177 | 178 | 179 |
180 | 181 | ##Fetch your records 182 | 183 | You can fetch your objects easily. 184 | Note that parameters 'predicate' and 'sortDescriptors' are optional 185 | 186 | ``` 187 | instance.fetchRecords(entityName: #ENTITY#, predicate: #PREDICATE#, sortDescriptors: #SORTDECRIPTORS#, completion: #COMPLETION BLOCK#) 188 | ``` 189 | 190 | You can easily check the object's existence or fetch the required persist data 191 | 192 | ```ruby 193 | instance.fetchRecords(entityName: .myEntity, sortDescriptors: [sorter]) { (results) in 194 | if let result = results { 195 | // MARK:- Record(s) found 196 | // You can fetch using loop 197 | } 198 | else { 199 | // MARK:- No Record found 200 | // You can insert new record to avoid redundancy 201 | } 202 | } 203 | ``` 204 | 205 | 206 | 207 | 208 |
209 | 210 | ##Delete a object 211 | 212 | You can easily delete an object using shared instance. 213 | 214 | ``` 215 | instance.deleteRecord(record) 216 | ``` 217 | 218 | > **Tip:** Don't forget to save changes after update persisted data using `instance.saveContext()` 219 | > 220 | 221 | 222 | 223 |
224 | 225 | ##Delete all objects 226 | 227 | You can easily remove all the records from an entity using shared instance 228 | 229 | ``` 230 | instance.deleteAllRecords(entity: .Example) 231 | ``` 232 | 233 | 234 | 235 |
236 | 237 | #Contributions & License 238 | 239 | `AACoreData` is available under the MIT license. See the [LICENSE](./LICENSE) file for more info. 240 | 241 | Pull requests are welcome! The best contributions will consist of substitutions or configurations for classes/methods known to block the main thread during a typical app lifecycle. 242 | 243 | I would love to know if you are using `AACoreData` in your app, send an email to [Engr. Ahsan Ali](mailto:hafiz.m.ahsan.ali@gmail.com) 244 | -------------------------------------------------------------------------------- /Screenshots/demo.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EngrAhsanAli/AACoreData/08ccb9c933457785b32b59c34de0cd80e675d9b8/Screenshots/demo.gif -------------------------------------------------------------------------------- /_Pods.xcodeproj: -------------------------------------------------------------------------------- 1 | Example/Pods/Pods.xcodeproj --------------------------------------------------------------------------------