YapDatabaseRTreeIndexHandler
@interface YapDatabaseRTreeIndexHandler : NSObject
The handler block handles extracting the column values for the rtree index.
When you add or update rows in the databse the block is invoked. Your block can inspect the row and determine if it contains any values that should be added to the rtree index. If not, the block can simply return. Otherwise the block should add a min and max value (can be equal) for each indexed dimension to the given dictionary.
After the block returns, the dictionary parameter will be inspected, and any set values will be automatically inserted/updated within the sqlite index.
You should choose a block type that takes the minimum number of required parameters. The extension can make various optimizations based on required parameters of the block. For example, if metadata isn’t required, then the extension can ignore metadata-only updates.
-
Undocumented
Declaration
Objective-C
+ (instancetype)withKeyBlock:(YapDatabaseRTreeIndexWithKeyBlock)block;
Swift
class func withKeyBlock(_ block: @escaping YapDatabaseRTreeIndexWithKeyBlock) -> Self
-
Undocumented
Declaration
Objective-C
+ (instancetype)withObjectBlock:(YapDatabaseRTreeIndexWithObjectBlock)block;
Swift
class func withObjectBlock(_ block: @escaping YapDatabaseRTreeIndexWithObjectBlock) -> Self
-
Undocumented
Declaration
Objective-C
+ (instancetype)withMetadataBlock:(YapDatabaseRTreeIndexWithMetadataBlock)block;
Swift
class func withMetadataBlock(_ block: @escaping YapDatabaseRTreeIndexWithMetadataBlock) -> Self
-
Undocumented
Declaration
Objective-C
+ (instancetype)withRowBlock:(YapDatabaseRTreeIndexWithRowBlock)block;
Swift
class func withRowBlock(_ block: @escaping YapDatabaseRTreeIndexWithRowBlock) -> Self
-
Undocumented
Declaration
Objective-C
+ (instancetype)withOptions:(YapDatabaseBlockInvoke)ops keyBlock:(YapDatabaseRTreeIndexWithKeyBlock)block;
Swift
class func withOptions(_ ops: YapDatabaseBlockInvoke, keyBlock block: @escaping YapDatabaseRTreeIndexWithKeyBlock) -> Self
-
Undocumented
Declaration
Objective-C
+ (instancetype)withOptions:(YapDatabaseBlockInvoke)ops objectBlock:(YapDatabaseRTreeIndexWithObjectBlock)block;
Swift
class func withOptions(_ ops: YapDatabaseBlockInvoke, objectBlock block: @escaping YapDatabaseRTreeIndexWithObjectBlock) -> Self
-
Undocumented
Declaration
Objective-C
+ (instancetype)withOptions:(YapDatabaseBlockInvoke)ops metadataBlock:(YapDatabaseRTreeIndexWithMetadataBlock)block;
Swift
class func withOptions(_ ops: YapDatabaseBlockInvoke, metadataBlock block: @escaping YapDatabaseRTreeIndexWithMetadataBlock) -> Self
-
Undocumented
Declaration
Objective-C
+ (instancetype)withOptions:(YapDatabaseBlockInvoke)ops rowBlock:(YapDatabaseRTreeIndexWithRowBlock)block;
Swift
class func withOptions(_ ops: YapDatabaseBlockInvoke, rowBlock block: @escaping YapDatabaseRTreeIndexWithRowBlock) -> Self
-
Undocumented
Declaration
Objective-C
@property (nonatomic, strong, readonly) YapDatabaseRTreeIndexBlock block
Swift
var block: Any { get }
-
Undocumented
Declaration
Objective-C
@property (nonatomic, assign, readonly) YapDatabaseBlockType blockType
Swift
var blockType: YapDatabaseBlockType { get }
-
Undocumented
Declaration
Objective-C
@property (nonatomic, assign, readonly) YapDatabaseBlockInvoke blockInvokeOptions
Swift
var blockInvokeOptions: YapDatabaseBlockInvoke { get }