Couchbase Lite
Objective-C API for iOS and Mac OS
CBLModelArray Class Reference

Detailed Description

An array of CBLModel objects, that's actually backed by document IDs.

It looks up the model dynamically as each item is accessed. This class is used by CBLModel for array-valued properties whose item type is a subclass of CBLModel.

Inheritance diagram for CBLModelArray:

Instance Methods

(instancetype) - initWithOwner:property:itemClass:docIDs:
 Initializes a model array from an array of document ID strings. More...
 
(instancetype) - initWithOwner:property:itemClass:models:
 Initializes a model array from an array of CBLModels. More...
 
() - CBLArrayOf
 

Method Documentation

◆ initWithOwner:property:itemClass:docIDs:()

- (instancetype) initWithOwner: (CBLModel *)  owner
property: (nullable NSString *)  property
itemClass: (nullable Class)  itemClass
docIDs: (CBLArrayOf(NSString *) *)  docIDs 

Initializes a model array from an array of document ID strings.

Returns nil if docIDs contains items that are non-strings, or invalid document IDs.

◆ initWithOwner:property:itemClass:models:()

- (instancetype) initWithOwner: (CBLModel *)  owner
property: (nullable NSString *)  property
itemClass: (nullable Class)  itemClass
models: (CBLArrayOf(CBLModel *) *)  models 

Initializes a model array from an array of CBLModels.

◆ CBLArrayOf()

- CBLArrayOf (NSString *) 

The documentation for this class was generated from the following file: