/** * @module common */ /** End Typedoc Module Declaration */ import { AbstractModel, identifier } from './model'; /** * Collection holds an array of [[AbstractModel|models]]. It provides common collection manipulation * methods for the controllers, services etc to work with models in an abstracted manner */ export declare class Collection extends Array { constructor(initialItems?: T[]); /** * Find an item in the collection by primary identifier * @param id * @returns {T} */ findById(id: identifier): T; /** * Remove an item from the collection * @param model */ remove(model: T): void; /** * Check if the collection contains a given model * @param model * @returns {boolean} */ contains(model: T): boolean; }