DropboxSync 0.2.1

DropboxSync 0.2.1

TestsTested
LangLanguage SwiftSwift
License MIT
ReleasedLast Release Aug 2016
SPMSupports SPM

Maintained by Daniel Green.



 
Depends on:
SwiftyDropbox~> 3.1
SwiftyJSON~> 2.3
 

By implementing the DropboxSyncable protocol methods in your class will make the class syncable via Dropbox:

public protocol DropboxSyncable {
    func uniqueIdentifier() -> String
    func lastUpdatedDate() -> NSDate
    func serializeForSync() -> NSData
    static func deserializeForSync(data: NSData)
}

There are many different ways to "sync" files. DropboxSync will currently, quite naively, replace versions stored in Dropbox with the most recently changed. It's simple, but for the moment it fulfills my own requirements. Pull requests very welcome.

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Installation

DropboxSync is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod "DropboxSync"

Author

Daniel Inkpen, [email protected]

License

DropboxSync is available under the MIT license. See the LICENSE file for more info.