RealmAdditions
RealmBool, RealmDouble, RealmInt, RealmString, RealmValue was deprecated. Realm 3 supports basic types natively.
Adds Realm representation for Int, String, Double and Bool. This allows to store them in Realm Lists.
Example
To run the example project, clone the repo, and run pod install
from the Example directory first.
Installation
Carthage
Please check official guide
Cartfile:
github "APUtils/RealmAdditions"
CocoaPods
RealmAdditions is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'RealmAdditions'
Usage
// Compile time error. List can't hold Strings
// let stringsList = List<String>
let realmString = RealmString(swiftValue: "string")
let list = List<RealmString>()
list.append(realmString)
print(list.first!.value)
See example and test projects for more details.
Contributions
Any contribution is more than welcome! You can contribute through pull requests and issues on GitHub.
Author
Anton Plebanovich, [email protected]
License
RealmAdditions is available under the MIT license. See the LICENSE file for more info.