Class ElementStore

Constructors

Properties

elements: Map<string, Element> = ...
elementSchemas: Map<string, ElementSchema> = ...
elementsTypeDataV1: Map<string, AttributeDefinitions> = ...
elementTemplates: Map<string, Template> = ...
elementTemplatesV1: ElementsTemplates = ...
main: MainStore
privileges: ElementsPrivileges = ...
socketEventIds: string[] = []
syncProgress: undefined | SyncProgress
workRecordActions: Map<string, string[]> = ...
listeners: () => void[] = []

Methods

  • Parameters

    Returns void

  • Parameters

    Returns void

  • Parameters

    • type: string
    • actions: string[]

    Returns void

  • Parameters

    Returns void

  • Parameters

    • elements: Element[]
    • attributes: string[]

    Returns Promise<undefined | BatchMetadata<string>>

  • Parameters

    Returns string

  • Parameters

    Returns Promise<undefined | Element>

  • Type Parameters

    Parameters

    Returns Promise<null | T>

  • Parameters

    • type: string
    • attributeKey: string

    Returns undefined | AttributeType

  • Parameters

    • hash: string

    Returns Promise<Element>

  • Parameters

    • url: string

    Returns Promise<Element>

  • Parameters

    • type: string
    • organization: string

    Returns Promise<undefined | ElementPrivileges>

  • Parameters

    • type: string

    Returns Promise<undefined | ElementSchema>

  • Parameters

    • type: string
    • organization: string

    Returns Promise<undefined | ElementTemplateV1>

  • Parameters

    Returns { conflictHashes: string[]; localFiles: LocalFile[] }

  • Parameters

    • type: undefined | string

    Returns typeof Element

  • Parameters

    • type: string
    • templateId: string = DEFAULT_TEMPLATE_ID

    Returns Promise<undefined | Template>

  • Parameters

    • hash: string
    • Optionaldata: ElementData
    • shouldLoad: boolean = false
    • paramOptions: Partial<InstantiateElementOptions> = {}

    Returns undefined | Element

  • Parameters

    • type: string
    • organization: string
    • Optionaldata: Omit<ElementData, "organization" | "hash" | "_type">
    • Optionalparent: Element

    Returns __type<GConstructor<Element>> & Element

  • Parameters

    • hashes: string[]
    • projection: string[] = []
    • OptionalparamOptions: { setToMemory?: boolean }

    Returns Promise<Element[]>

  • Parameters

    • Optionalright: "read" | "update" | "create"

    Returns Promise<string[]>

  • Returns Promise<void>

  • Parameters

    • change: IObjectDidChange

    Returns Promise<void>

  • Parameters

    • hash: string

    Returns Promise<undefined | Element>

  • Returns Promise<void>

  • Parameters

    • hash: string

    Returns undefined | Promise<void>

  • Parameters

    Returns undefined | Promise<void>

  • Parameters

    • type: string
    • template: Template
    • templateId: string = DEFAULT_TEMPLATE_ID

    Returns void

  • Parameters

    Returns undefined | () => void

  • Returns Promise<void>

  • Parameters

    Returns boolean