ActiveUI

ActiveUI

  • User Guide
  • Developer Documentation

Home > @activeviam/activeui-sdk > MdxQuery

MdxQuery interface

A MDX query on a given server.

Signature:

export interface MdxQuery 

Properties

PropertyTypeDescription
_getMultiBinding() => MultiBinding
_waitUntilLoaded() => Promise<void>
addListener(a: (a: Table) => void) => RemoveListenerAdd a listener that will be called when the server send an update for this query.
cancel() => void
dispose() => voidStop the query and unregister all the internal listeners.
executeOnceAndGetPromise() => Promise<CellSet>
getContext() => MdxContextValues
getId() => QueryId
getMdx() => Mdx
getPlaygroundBinding() => BindingWrapper
getRanges() => Ranges
getRefreshInterval() => number
getUpdateMode() => UpdateMode
hasStarted() => boolean
isRealTime() => booleanCheck whether the query is currently running continuously.
refresh() => void
refreshAndGetPromise() => Promise<CellSetMessage | null | undefined>
refreshPeriodically(a: number) => MdxQueryStart the query in refresh periodically mode, and publish results to the feed
setContext(a: MdxContextValues) => MdxQueryChange the query context values and restart the query if currently running.
setMdx(a: Mdx) => MdxQueryChange the query MDX and restart the query if currently running.
setRanges(a: Ranges) => MdxQuery
setRefreshInterval(a: number) => void
start(a?: UpdateMode | null | undefined, b?: number | null | undefined) => MdxQueryStart the query and publish the results to the feed.
stop() => MdxQueryStop the continuous query.
toggle() => MdxQueryToggle the query state: start it if stopped and stop it if started.
update(a: Mdx, b: MdxContextValues, c: UpdateMode, d: number) => MdxQueryChange the query MDX and/or context values and/or updateMode atomically. If the query is currently running, it will be stopped and started again with the new parameters.

Remarks

A MdxQuery has two ids: clientId and serverId:

  • clientId: a unique id among all the queries in this loaded ActiveUI application. Used to find again a query in the queries pool. This id is assigned when the query is created and never changes. This is the same ID we will use to match the server 'streamId' notion.

  • serverId: a id that changes every time the mdx or the context values of this query change. This is the id we send to the server so that we can match WebSocket queries updates with their corresponding query state (especially drop updates that we receive just after having changed the MDX for instance because they are not consistent with the cellSet we expect to have with this MDX). This id is also unique among all running queries in this loaded ActiveUI application.

  • MdxQuery interface
  • Properties
  • Remarks
Copyright © 2019 ActiveViam