Internal_The source data array from which the Documents in the WorldCollection are created
An Array of application references which will be automatically updated when the collection content changes
Record the set of document ids where the Document was not initialized because of invalid source data
The CompendiumCollection instance that contains this CompendiumFolderCollection
StaticdocumentThe base Document type which is contained within this DocumentCollection
Return an Array of all the entry values in the Collection
A reference to the Document class definition which is contained within this DocumentCollection.
The Collection class name
Apply a function to each element of the collection
Get an element from the DocumentCollection by its ID.
The ID of the Document to retrieve.
Optionaloptions: { invalid?: boolean; strict?: boolean } = {}Additional options to configure retrieval.
Optionalinvalid?: booleanAllow retrieving an invalid Document.
Optionalstrict?: booleanThrow an Error if the requested Document does not exist.
Obtain a temporary Document instance for a document id which currently has invalid source data.
A document ID with invalid source data.
Optionaloptions: { strict?: boolean } = {}Additional options to configure retrieval.
Optionalstrict?: booleanThrow an Error if the requested ID is not in the set of invalid IDs for this collection.
An in-memory instance for the invalid Document
Get an entry from the Collection by name. Use of this method assumes that the objects stored in the collection have a "name" attribute.
The name of the entry to retrieve
Optionaloptions: { strict?: boolean } = {}Additional options that affect how entries are retrieved
Optionalstrict?: booleanThrow an Error if the requested name does not exist. Default false.
The retrieved entry value, if one was found, otherwise undefined
Import a Document into this collection, persisting the result. If the document ID already exists in the collection, it should be replaced with an optional confirmation dialog. If the document ID is undefined or does not already exist, a new Document will be created in the collection.
A source Document to be imported. The document will be safely copied.
Options which modify import behavior
The imported Document instance
Find all Documents which match a given search term using a full-text search against their indexed HTML fields and their name. If filters are provided, results are filtered to only those that match the provided values.
An object configuring the search
Optionalexclude?: string[]An array of document IDs to exclude from search results
Optionalfilters?: FieldFilter[]An array of filters to apply
Optionalquery?: stringA case-insensitive search string
Test whether a condition is met by some entry in the Collection.
The functional condition to test.
Was the test condition passed by at least one entry?
Convert the Collection to a primitive array of its contents.
An array of contained values
Update all objects in this DocumentCollection with a provided transformation. Conditionally filter to only apply to Entities which match a certain condition.
An object of data or function to apply to all matched objects
A function which tests whether to target each object
Additional options passed to Document.updateDocuments
An array of updated data once the operation is complete
Protected_ProtectedInitialize the DocumentCollection by constructing any initially provided Document instances
StaticgetGet the searchable fields for a given document or index, based on its data model
The document name
Optionaltype: stringA document subtype
A record of searchable DataField definitions
A Collection of Folder documents within a Compendium pack.