Releases: realm/realm-swift
Releases · realm/realm-swift
v0.95.3
Bugfixes
- Compile iOS Simulator framework architectures with
-fembed-bitcode-marker
.
- Fix crashes when the first Realm opened uses a class subset and later Realms
opened do not.
- Fix inconsistent errors when
Object(value: ...)
is used to initialize the
default value of a property of an Object
subclass.
- Throw an exception when a class subset has objects with array or object
properties of a type that are not part of the class subset.
v0.95.2
- Enable bitcode for iOS and watchOS frameworks.
- Build libraries with Xcode 7 final rather than the GM.
v0.95.1
Enhancements
- Add missing KVO handling for moving and exchanging objects in
RLMArray
and
List
.
Bugfixes
- Setting the primary key property on persisted
RLMObject
s / Object
s
via subscripting or key-value coding will cause an exception to be thrown.
- Fix crash due to race condition in
RLMRealmConfiguration
where the default
configuration was in the process of being copied in one thread, while
released in another.
- Fix crash when a migration which removed an object or array property is
rolled back due to an error.
v0.95.0
API breaking changes
- The following APIs have been deprecated in favor of the new
RLMRealmConfiguration
class in Realm Objective-C:
Deprecated API |
New API |
+[RLMRealm realmWithPath:readOnly:error:] |
+[RLMRealm realmWithConfiguration:error:] |
+[RLMRealm realmWithPath:encryptionKey:readOnly:error:] |
+[RLMRealm realmWithConfiguration:error:] |
+[RLMRealm setEncryptionKey:forRealmsAtPath:] |
-[RLMRealmConfiguration setEncryptionKey:] |
+[RLMRealm inMemoryRealmWithIdentifier:] |
+[RLMRealm realmWithConfiguration:error:] |
+[RLMRealm defaultRealmPath] |
+[RLMRealmConfiguration defaultConfiguration] |
+[RLMRealm setDefaultRealmPath:] |
+[RLMRealmConfiguration setDefaultConfiguration:] |
+[RLMRealm setDefaultRealmSchemaVersion:withMigrationBlock] |
RLMRealmConfiguration.schemaVersion and RLMRealmConfiguration.migrationBlock |
+[RLMRealm setSchemaVersion:forRealmAtPath:withMigrationBlock:] |
RLMRealmConfiguration.schemaVersion and RLMRealmConfiguration.migrationBlock |
+[RLMRealm migrateRealmAtPath:] |
+[RLMRealm migrateRealm:] |
+[RLMRealm migrateRealmAtPath:encryptionKey:] |
+[RLMRealm migrateRealm:] |
- The following APIs have been deprecated in favor of the new
Realm.Configuration
struct in Realm Swift for Swift 1.2:
Deprecated API |
New API |
Realm.defaultPath |
Realm.Configuration.defaultConfiguration |
Realm(path:readOnly:encryptionKey:error:) |
Realm(configuration:error:) |
Realm(inMemoryIdentifier:) |
Realm(configuration:error:) |
Realm.setEncryptionKey(:forPath:) |
Realm(configuration:error:) |
setDefaultRealmSchemaVersion(schemaVersion:migrationBlock:) |
Realm.Configuration.schemaVersion and Realm.Configuration.migrationBlock |
setSchemaVersion(schemaVersion:realmPath:migrationBlock:) |
Realm.Configuration.schemaVersion and Realm.Configuration.migrationBlock |
migrateRealm(path:encryptionKey:) |
migrateRealm(configuration:) |
- The following APIs have been deprecated in favor of the new
Realm.Configuration
struct in Realm Swift for Swift 2.0:
Deprecated API |
New API |
Realm.defaultPath |
Realm.Configuration.defaultConfiguration |
Realm(path:readOnly:encryptionKey:) throws |
Realm(configuration:) throws |
Realm(inMemoryIdentifier:) |
Realm(configuration:) throws |
Realm.setEncryptionKey(:forPath:) |
Realm(configuration:) throws |
setDefaultRealmSchemaVersion(schemaVersion:migrationBlock:) |
Realm.Configuration.schemaVersion and Realm.Configuration.migrationBlock |
setSchemaVersion(schemaVersion:realmPath:migrationBlock:) |
Realm.Configuration.schemaVersion and Realm.Configuration.migrationBlock |
migrateRealm(path:encryptionKey:) |
migrateRealm(configuration:) |
List.extend
in Realm Swift for Swift 2.0 has been replaced with List.appendContentsOf
,
mirroring changes to RangeReplaceableCollectionType
.
- Object properties on
Object
subclasses in Realm Swift must be marked as optional,
otherwise a runtime exception will be thrown.
Enhancements
- Persisted properties of
RLMObject
/Object
subclasses are now Key-Value
Observing compliant.
- The different options used to create Realm instances have been consolidated
into a single RLMRealmConfiguration
/Realm.Configuration
object.
- Enumerating Realm collections (
RLMArray
, RLMResults
, List<>
,
Results<>
) now enumerates over a copy of the collection, making it no
longer an error to modify a collection during enumeration (either directly,
or indirectly by modifying objects to make them no longer match a query).
- Improve performance of object insertion in Swift to bring it roughly in line
with Objective-C.
- Allow specifying a specific list of
RLMObject
/ Object
subclasses to include
in a given Realm via RLMRealmConfiguration.objectClasses
/ Realm.Configuration.objectTypes
.
Bugfixes
- Subscripting on
RLMObject
is now marked as nullable.
v0.94.1
API breaking changes
- Building for watchOS requires Xcode 7 beta 5.
Enhancements
Object.className
is now marked as final
.
Bugfixes
- Fix crash when adding a property to a model without updating the schema
version.
- Fix unnecessary redownloading of the core library when building from source.
- Fix crash when sorting by an integer or floating-point property on iOS 7.
v0.94.0
API breaking changes
Enhancements
- Reduce the amount of memory used by RLMRealm notification listener threads.
- Avoid evaluating results eagerly when filtering and sorting.
- Add nullability annotations to the Objective-C API to provide enhanced compiler
warnings and bridging to Swift.
- Make
RLMResult
s and RLMArray
s support Objective-C generics.
- Add support for building watchOS and bitcode-compatible apps.
- Make the exceptions thrown in getters and setters more informative.
- Add
-[RLMArray exchangeObjectAtIndex:withObjectAtIndex]
and List.swap(_:_:)
to allow exchanging the location of two objects in the given RLMArray
/ List
.
- Added anonymous analytics on simulator/debugger runs.
- Add
-[RLMArray moveObjectAtIndex:toIndex:]
and List.move(from:to:)
to
allow moving objects in the given RLMArray
/ List
.
Bugfixes
- Processes crashing due to an uncaught exception inside a write transaction will
no longer cause other processes using the same Realm to hang indefinitely.
- Fix incorrect results when querying for < or <= on ints that
require 64 bits to represent with a CPU that supports SSE 4.2.
- An exception will no longer be thrown when attempting to reset the schema
version or encryption key on an open Realm to the current value.
- Date properties on 32 bit devices will retain 64 bit second precision.
- Wrap calls to the block passed to
enumerate
in an autoreleasepool to reduce
memory growth when migrating a large amount of objects.
- In-memory realms no longer write to the Documents directory on iOS or
Application Support on OS X.
v0.93.2
Bugfixes
- Fixed an issue where the packaged OS X Realm.framework was built with
GCC_GENERATE_TEST_COVERAGE_FILES
and GCC_INSTRUMENT_PROGRAM_FLOW_ARCS
enabled.
- Fix a memory leak when constructing standalone Swift objects with NSDate
properties.
- Throw an exception rather than asserting when an invalidated object is added
to an RLMArray.
- Fix a case where data loss would occur if a device was hard-powered-off
shortly after a write transaction was committed which had to expand the Realm
file.
v0.93.1
Bugfixes
- Objects are no longer copied into standalone objects during object creation. This fixes an issue where nested objects with a primary key are sometimes duplicated rather than updated.
- Comparison predicates with a constant on the left of the operator and key path on the right now give correct results. An exception is now thrown for predicates that do not yet support this ordering.
- Fix some crashes in
index_string.cpp
with int primary keys or indexed int properties.
v0.93.0
API breaking changes
- Schema versions are now represented as
uint64_t
(Objective-C) and UInt64
(Swift) so that they have
the same representation on all architectures.
Enhancements
- Swift:
Results
now conforms to CVarArgType
so it can
now be passed as an argument to Results.filter(_:...)
and List.filter(_:...)
.
- Swift: Made
SortDescriptor
conform to the Equatable
and
StringLiteralConvertible
protocols.
- Int primary keys are once again automatically indexed.
- Improve error reporting when attempting to mark a property of a type that
cannot be indexed as indexed.
Bugfixes
- Swift:
RealmSwift.framework
no longer embeds Realm.framework
,
which now allows apps using it to pass iTunes Connect validation.
v0.92.4
API breaking changes
Enhancements
- Swift: Made
Object.init()
a required initializer.
RLMObject
, RLMResults
, Object
and Results
can now be safely
deallocated (but still not used) from any thread.
- Improve performance of
-[RLMArray indexOfObjectWhere:]
and -[RLMArray indexOfObjectWithPredicate:]
, and implement them for standalone RLMArrays.
- Improved performance of most simple queries.
Bugfixes
- The interprocess notification mechanism no longer uses dispatch worker threads, preventing it from
starving other GCD clients of the opportunity to execute blocks when dozens of Realms are open at once.