Foundry Virtual Tabletop - API Documentation - Version 14
    Preparing search index...

    Class ClientDatabaseBackend

    The client-side database backend implementation which handles Document modification operations.

    Hierarchy (View Summary)

    Index

    Methods

    • Internal

      Activate the Socket event listeners used to receive responses from events which modify database documents

      Parameters

      • socket: Socket<DefaultEventsMap, DefaultEventsMap>

        The active game socket

      Returns void

    • Parameters

      • level: any
      • message: any

      Returns void

    • Describe the scopes which are suitable as the namespace for a flag key

      Returns any[]

    • Protected

      Log a database operation for an embedded document, capturing the action taken and relevant IDs

      Parameters

      • action: string

        The action performed

      • type: string

        The document type

      • documents: Document[]

        The documents modified

      • Optionalcontext: {
            dryRun?: boolean;
            level?: string;
            pack?: string;
            parent?: Document<object, DocumentConstructionContext>;
        } = {}

        The context of the log request

        • OptionaldryRun?: boolean

          Whether this operation is part of a dry run: abort true and level isn't "debug"

        • Optionallevel?: string

          The logging level

        • Optionalpack?: string

          A compendium pack within which the operation occurred

        • Optionalparent?: Document<object, DocumentConstructionContext>

          A parent document

      Returns void