diff --git a/.cocoapods.yml b/.cocoapods.yml new file mode 100644 index 0000000..d89dd88 --- /dev/null +++ b/.cocoapods.yml @@ -0,0 +1,5 @@ +try: + install: + pre: + - git submodule foreach --recursive git submodule update --init + project: 'Example/DTCollectionViewManager.xcodeproj' diff --git a/CHANGELOG.md b/CHANGELOG.md index f2733d6..46741ac 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,9 +1,9 @@ # Change Log All notable changes to this project will be documented in this file. -## Master +## [4.5.0](https://github.com/DenHeadless/DTCollectionViewManager/releases/tag/4.5.0) -## Added +## Added * Support for Realm database storage - using `RealmStorage` class. * `batchUpdatesInProgress` property on `DTCollectionViewManager` that indicates if batch updates are finished or not. diff --git a/Cartfile b/Cartfile index 5b36e0c..f11fcc0 100644 --- a/Cartfile +++ b/Cartfile @@ -1 +1 @@ -github "DenHeadless/DTModelStorage" "master" +github "DenHeadless/DTModelStorage" ~> 2.4.0 diff --git a/Cartfile.resolved b/Cartfile.resolved index 8f66f1e..f000ea5 100644 --- a/Cartfile.resolved +++ b/Cartfile.resolved @@ -1,3 +1,3 @@ github "Quick/Nimble" "v3.0.0" github "realm/realm-cocoa" "v0.97.0" -github "DenHeadless/DTModelStorage" "32550cd75b9dd31a7d78af9c941f55254e76acca" +github "DenHeadless/DTModelStorage" "2.4.0" diff --git a/Carthage/Checkouts/DTModelStorage b/Carthage/Checkouts/DTModelStorage index 32550cd..e5f860f 160000 --- a/Carthage/Checkouts/DTModelStorage +++ b/Carthage/Checkouts/DTModelStorage @@ -1 +1 @@ -Subproject commit 32550cd75b9dd31a7d78af9c941f55254e76acca +Subproject commit e5f860fb39d9743c662e28c9957fc0a2adfedb9b diff --git a/DTCollectionViewManager.podspec b/DTCollectionViewManager.podspec index c88c864..5e31aa2 100644 --- a/DTCollectionViewManager.podspec +++ b/DTCollectionViewManager.podspec @@ -1,16 +1,16 @@ Pod::Spec.new do |s| s.name = 'DTCollectionViewManager' - s.version = '4.4.2' + s.version = '4.5.0' s.license = 'MIT' s.summary = 'Protocol-oriented UICollectionView management, powered by generics and associated types.' s.homepage = 'https://github.com/DenHeadless/DTCollectionViewManager' s.authors = { 'Denys Telezhkin' => 'denys.telezhkin@yandex.ru' } s.social_media_url = 'https://twitter.com/DTCoder' s.source = { :git => 'https://github.com/DenHeadless/DTCollectionViewManager.git', :tag => s.version.to_s } - s.source_files = 'DTCollectionViewManager/**/*.{h,swift}' + s.source_files = 'Sources/*.swift' s.requires_arc = true s.ios.deployment_target = '8.0' s.tvos.deployment_target = '9.0' s.frameworks = 'UIKit', 'Foundation' - s.dependency 'DTModelStorage' , '~> 2.3.0' + s.dependency 'DTModelStorage' , '~> 2.4.0' end diff --git a/Example/DTCollectionViewManager.xcodeproj/project.pbxproj b/Example/DTCollectionViewManager.xcodeproj/project.pbxproj index a86fb2c..867cc10 100644 --- a/Example/DTCollectionViewManager.xcodeproj/project.pbxproj +++ b/Example/DTCollectionViewManager.xcodeproj/project.pbxproj @@ -7,6 +7,8 @@ objects = { /* Begin PBXBuildFile section */ + 9A006F381C3C22D80074E924 /* SectionModel+ConvenienceGetters.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9A006F371C3C22D80074E924 /* SectionModel+ConvenienceGetters.swift */; }; + 9A006F391C3C22D80074E924 /* SectionModel+ConvenienceGetters.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9A006F371C3C22D80074E924 /* SectionModel+ConvenienceGetters.swift */; }; 9A08A9C91B8A249300877C62 /* DTCollectionViewManager.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9AE671491AEE61F800B25A5F /* DTCollectionViewManager.framework */; }; 9A2109E31B9C58E20036D151 /* ComplexLayoutViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9A2109E21B9C58E20036D151 /* ComplexLayoutViewController.swift */; }; 9A2109E71B9C5A020036D151 /* CollectionContainingCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9A2109E61B9C5A020036D151 /* CollectionContainingCell.swift */; }; @@ -30,7 +32,6 @@ 9A99AA861B8A219300428802 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 9A99AA841B8A219300428802 /* Main.storyboard */; }; 9A99AA881B8A219300428802 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 9A99AA871B8A219300428802 /* Assets.xcassets */; }; 9A99AA8B1B8A219300428802 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 9A99AA891B8A219300428802 /* LaunchScreen.storyboard */; }; - 9AC5320E1BE5F74B006CB18A /* SectionModel+ConvenienceGetters.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9AF55A651BA473F90067D0C1 /* SectionModel+ConvenienceGetters.swift */; }; 9AC532101BE5F74B006CB18A /* CollectionViewFactory.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9AF55A5E1BA473EA0067D0C1 /* CollectionViewFactory.swift */; }; 9AC532111BE5F74B006CB18A /* DTCollectionViewManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9AF55A5F1BA473EA0067D0C1 /* DTCollectionViewManager.swift */; }; 9AC532171BE5F77F006CB18A /* SupplementaryMappingTestCase.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9A2C6E421BE3ED4C001D25DB /* SupplementaryMappingTestCase.swift */; }; @@ -80,7 +81,6 @@ 9ADFC8F91B8B771800AB4CD9 /* SimpleTextCollectionReusableView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 9ADFC8F71B8B771800AB4CD9 /* SimpleTextCollectionReusableView.xib */; }; 9AF55A601BA473EA0067D0C1 /* CollectionViewFactory.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9AF55A5E1BA473EA0067D0C1 /* CollectionViewFactory.swift */; }; 9AF55A611BA473EA0067D0C1 /* DTCollectionViewManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9AF55A5F1BA473EA0067D0C1 /* DTCollectionViewManager.swift */; }; - 9AF55A681BA473F90067D0C1 /* SectionModel+ConvenienceGetters.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9AF55A651BA473F90067D0C1 /* SectionModel+ConvenienceGetters.swift */; }; 9AF938A51C0C966F0051E8E8 /* VIewModelMappingCustomizableTestCase.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9AF938A41C0C966F0051E8E8 /* VIewModelMappingCustomizableTestCase.swift */; }; 9AF938A61C0C966F0051E8E8 /* VIewModelMappingCustomizableTestCase.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9AF938A41C0C966F0051E8E8 /* VIewModelMappingCustomizableTestCase.swift */; }; 9AF938A81C0C9E0D0051E8E8 /* CollectionViewFactoryTestCase.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9AF938A71C0C9E0D0051E8E8 /* CollectionViewFactoryTestCase.swift */; }; @@ -196,6 +196,7 @@ /* End PBXCopyFilesBuildPhase section */ /* Begin PBXFileReference section */ + 9A006F371C3C22D80074E924 /* SectionModel+ConvenienceGetters.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = "SectionModel+ConvenienceGetters.swift"; path = "../Sources/SectionModel+ConvenienceGetters.swift"; sourceTree = ""; }; 9A2109E21B9C58E20036D151 /* ComplexLayoutViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ComplexLayoutViewController.swift; sourceTree = ""; }; 9A2109E61B9C5A020036D151 /* CollectionContainingCell.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = CollectionContainingCell.swift; path = Cells/CollectionContainingCell.swift; sourceTree = ""; }; 9A2C6E421BE3ED4C001D25DB /* SupplementaryMappingTestCase.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SupplementaryMappingTestCase.swift; sourceTree = ""; }; @@ -249,10 +250,9 @@ 9ADFC8F61B8B771800AB4CD9 /* SimpleTextCollectionReusableView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = SimpleTextCollectionReusableView.swift; path = Views/SimpleTextCollectionReusableView.swift; sourceTree = ""; }; 9ADFC8F71B8B771800AB4CD9 /* SimpleTextCollectionReusableView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; name = SimpleTextCollectionReusableView.xib; path = Views/SimpleTextCollectionReusableView.xib; sourceTree = ""; }; 9AE671491AEE61F800B25A5F /* DTCollectionViewManager.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = DTCollectionViewManager.framework; sourceTree = BUILT_PRODUCTS_DIR; }; - 9AE6714C1AEE61F800B25A5F /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; - 9AF55A5E1BA473EA0067D0C1 /* CollectionViewFactory.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = CollectionViewFactory.swift; path = ../DTCollectionViewManager/CollectionViewFactory.swift; sourceTree = ""; }; - 9AF55A5F1BA473EA0067D0C1 /* DTCollectionViewManager.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = DTCollectionViewManager.swift; path = ../DTCollectionViewManager/DTCollectionViewManager.swift; sourceTree = ""; }; - 9AF55A651BA473F90067D0C1 /* SectionModel+ConvenienceGetters.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = "SectionModel+ConvenienceGetters.swift"; path = "../DTCollectionViewManager/Utilities/SectionModel+ConvenienceGetters.swift"; sourceTree = ""; }; + 9AE6714C1AEE61F800B25A5F /* .. */ = {isa = PBXFileReference; lastKnownFileType = folder; path = ..; sourceTree = ""; }; + 9AF55A5E1BA473EA0067D0C1 /* CollectionViewFactory.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = CollectionViewFactory.swift; path = ../Sources/CollectionViewFactory.swift; sourceTree = ""; }; + 9AF55A5F1BA473EA0067D0C1 /* DTCollectionViewManager.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = DTCollectionViewManager.swift; path = ../Sources/DTCollectionViewManager.swift; sourceTree = ""; }; 9AF938A41C0C966F0051E8E8 /* VIewModelMappingCustomizableTestCase.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = VIewModelMappingCustomizableTestCase.swift; sourceTree = ""; }; 9AF938A71C0C9E0D0051E8E8 /* CollectionViewFactoryTestCase.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = CollectionViewFactoryTestCase.swift; sourceTree = ""; }; /* End PBXFileReference section */ @@ -333,7 +333,7 @@ 955F85AE179ACB7300A38EAD /* DTCollectionViewManager */ = { isa = PBXGroup; children = ( - 9ADFC8BD1B8A301300AB4CD9 /* Utilities */, + 9A006F371C3C22D80074E924 /* SectionModel+ConvenienceGetters.swift */, 9AF55A5E1BA473EA0067D0C1 /* CollectionViewFactory.swift */, 9AF55A5F1BA473EA0067D0C1 /* DTCollectionViewManager.swift */, ); @@ -448,14 +448,6 @@ name = tvOS; sourceTree = ""; }; - 9ADFC8BD1B8A301300AB4CD9 /* Utilities */ = { - isa = PBXGroup; - children = ( - 9AF55A651BA473F90067D0C1 /* SectionModel+ConvenienceGetters.swift */, - ); - name = Utilities; - sourceTree = ""; - }; 9ADFC8C61B8B4A2200AB4CD9 /* Helpers */ = { isa = PBXGroup; children = ( @@ -510,7 +502,7 @@ 9AE6714B1AEE61F800B25A5F /* Supporting Files */ = { isa = PBXGroup; children = ( - 9AE6714C1AEE61F800B25A5F /* Info.plist */, + 9AE6714C1AEE61F800B25A5F /* .. */, ); name = "Supporting Files"; sourceTree = ""; @@ -822,7 +814,7 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( - 9AC5320E1BE5F74B006CB18A /* SectionModel+ConvenienceGetters.swift in Sources */, + 9A006F391C3C22D80074E924 /* SectionModel+ConvenienceGetters.swift in Sources */, 9AC532101BE5F74B006CB18A /* CollectionViewFactory.swift in Sources */, 9AC532111BE5F74B006CB18A /* DTCollectionViewManager.swift in Sources */, ); @@ -856,9 +848,9 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( + 9A006F381C3C22D80074E924 /* SectionModel+ConvenienceGetters.swift in Sources */, 9AF55A601BA473EA0067D0C1 /* CollectionViewFactory.swift in Sources */, 9AF55A611BA473EA0067D0C1 /* DTCollectionViewManager.swift in Sources */, - 9AF55A681BA473F90067D0C1 /* SectionModel+ConvenienceGetters.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -1082,7 +1074,7 @@ GCC_WARN_UNDECLARED_SELECTOR = YES; GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; - INFOPLIST_FILE = DTCollectionViewManager/Info.plist; + INFOPLIST_FILE = Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MTL_ENABLE_DEBUG_INFO = YES; @@ -1118,7 +1110,7 @@ GCC_WARN_UNDECLARED_SELECTOR = YES; GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; - INFOPLIST_FILE = DTCollectionViewManager/Info.plist; + INFOPLIST_FILE = Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MTL_ENABLE_DEBUG_INFO = NO; @@ -1205,7 +1197,7 @@ GCC_WARN_UNDECLARED_SELECTOR = YES; GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; - INFOPLIST_FILE = DTCollectionViewManager/Info.plist; + INFOPLIST_FILE = Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MTL_ENABLE_DEBUG_INFO = YES; @@ -1240,7 +1232,7 @@ GCC_WARN_UNDECLARED_SELECTOR = YES; GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; - INFOPLIST_FILE = DTCollectionViewManager/Info.plist; + INFOPLIST_FILE = Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MTL_ENABLE_DEBUG_INFO = NO; diff --git a/Example/DTCollectionViewManager/Info.plist b/Example/Info.plist similarity index 100% rename from Example/DTCollectionViewManager/Info.plist rename to Example/Info.plist diff --git a/README.md b/README.md index 14183b3..2e866ce 100644 --- a/README.md +++ b/README.md @@ -18,6 +18,7 @@ Powerful protocol-oriented UICollectionView management framework, written in Swi - [x] Support for protocols and subclasses as data models - [x] Views created from code, XIB, or storyboard - [x] Flexible Memory/CoreData/Custom storage options +- [x] Support for Realm.io databases - [x] Automatic datasource and interface synchronization. - [x] Automatic XIB registration and dequeue - [x] No type casts required @@ -34,11 +35,11 @@ Powerful protocol-oriented UICollectionView management framework, written in Swi [CocoaPods](http://www.cocoapods.org): - pod 'DTCollectionViewManager', '~> 4.4.2' + pod 'DTCollectionViewManager', '~> 4.5.0' [Carthage](https://github.com/Carthage/Carthage): - github "DenHeadless/DTCollectionViewManager" ~> 4.4.2 + github "DenHeadless/DTCollectionViewManager" ~> 4.5.0 After running `carthage update` drop DTCollectionViewManager.framework and DTModelStorage.framework to XCode project embedded binaries. diff --git a/DTCollectionViewManager/CollectionViewFactory.swift b/Sources/CollectionViewFactory.swift similarity index 100% rename from DTCollectionViewManager/CollectionViewFactory.swift rename to Sources/CollectionViewFactory.swift diff --git a/DTCollectionViewManager/DTCollectionViewManager.swift b/Sources/DTCollectionViewManager.swift similarity index 100% rename from DTCollectionViewManager/DTCollectionViewManager.swift rename to Sources/DTCollectionViewManager.swift diff --git a/DTCollectionViewManager/Utilities/SectionModel+ConvenienceGetters.swift b/Sources/SectionModel+ConvenienceGetters.swift similarity index 100% rename from DTCollectionViewManager/Utilities/SectionModel+ConvenienceGetters.swift rename to Sources/SectionModel+ConvenienceGetters.swift