Private #flagA cached array of valid flag scopes which can be read and written.
Retrieve Documents based on provided query parameters. It recommended to use CompendiumCollection#getDocuments or CompendiumCollection#getIndex rather than calling this method directly.
The Document class definition
Parameters of the get operation
Optional user: BaseUserThe requesting User
An array of retrieved Document instances or index objects
Create new Documents using provided data and context. It is recommended to use Document.createDocuments or Document.create rather than calling this method directly.
The Document class definition
Parameters of the create operation
Optional user: BaseUserThe requesting User
An array of created Document instances
Update Documents using provided data and context. It is recommended to use Document.updateDocuments or Document#update rather than calling this method directly.
The Document class definition
Parameters of the update operation
Optional user: BaseUserThe requesting User
An array of updated Document instances
Delete Documents using provided ids and context. It is recommended to use foundry.abstract.Document.deleteDocuments or foundry.abstract.Document#delete rather than calling this method directly.
The Document class definition
Parameters of the delete operation
Optional user: BaseUserThe requesting User
An array of deleted Document instances
Protected _logProtected Log a database operation for an embedded document, capturing the action taken and relevant IDs
The action performed
The document type
The documents modified
Optional __namedParameters: string = {}Protected _logPrivate #handlePrivate #handlePrivate #handlePrivate #onPrivate #configureValidate and configure the parameters of the get operation.
The requested operation
Private #configureValidate and configure the parameters of the create operation.
The requested operation
Private #configureValidate and configure the parameters of the update operation.
The requested operation
Private #configureValidate and configure the parameters of the delete operation.
The requested operation
Private #configurePrivate #logDetermine a string suffix for a log message based on the parent and/or compendium context.
Static Private #prePerform a standardized pre-creation workflow for all Document types. This workflow mutates the operation data array.
Static Private #prePerform a standardized pre-update workflow for all Document types. This workflow mutates the operation updates array.
Static Private #prePerform a standardized pre-delete workflow for all Document types. This workflow mutates the operation ids array.
Static Private #getObtain the document collection for a given Document class and database operation.
The Document class being operated upon
The database operation being performed
A parent Document, if applicable
A compendium pack identifier, if applicable
The relevant collection instance for this request
Static Private #buildStructure a database operation as a web socket request.
Static Private #dispatchDispatch a document modification socket request to the server.
Static Private #loadEnsure the given list of documents is loaded into the compendium collection so that they can be retrieved by subsequent operations.
The candidate collection.
An array of update deltas, or IDs, depending on the operation.
Static Private #adjustAugment a database operation with alterations needed to support ActorDelta and TokenDocuments.
The document class being operated upon
The document modification socket request
Static Private #getStatic Private #adjust
The client-side database backend implementation which handles Document modification operations.
Alias
foundry.data.ClientDatabaseBackend