123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127 |
- #import <Foundation/Foundation.h>
- NS_ASSUME_NONNULL_BEGIN
- @class RLMSchema;
- @class RLMArray;
- @class RLMObject;
- typedef void (^RLMObjectMigrationBlock)(RLMObject * __nullable oldObject, RLMObject * __nullable newObject);
- @interface RLMMigration : NSObject
- #pragma mark - Properties
- @property (nonatomic, readonly) RLMSchema *oldSchema;
- @property (nonatomic, readonly) RLMSchema *newSchema;
- #pragma mark - Altering Objects during a Migration
- - (void)enumerateObjects:(NSString *)className block:(__attribute__((noescape)) RLMObjectMigrationBlock)block;
- - (RLMObject *)createObject:(NSString *)className withValue:(id)value;
- - (void)deleteObject:(RLMObject *)object;
- - (BOOL)deleteDataForClassName:(NSString *)name;
- - (void)renamePropertyForClass:(NSString *)className oldName:(NSString *)oldName newName:(NSString *)newName;
- @end
- NS_ASSUME_NONNULL_END
|