DynamicCollection(Model)

new DynamicCollection(Model)

Creates a new DynamicCollection instance.

DynamicCollection is an extension of the native Array object thus implementing all of Array's methods and properties.

Parameters:
Name Type Description
Model DynamicRecord.Model

The Model constructor to use for this collection

Extends

  • Array

Members

data :Array

Returns a native array of data objects

Methods

saveAll() → {Promise}

Save all the model instances in the DynamicCollection.

Simply calls all the individual model's save() method.

Returns:
Promise