Interface JsResolvedTable

All Superinterfaces:
JsITable, JsTableOperations, ServerObject

@TsName(namespace="dh", name="ResolvedTable") @TsInterface public interface JsResolvedTable extends JsITable, JsTableOperations
The table an awaited JsPendingTable resolves to: a retained table whose data can be read, plus the chainable JsTableOperations, each of which again yields a JsPendingTable. Each instance points at a single server-side table, unlike a JsTable which can have its filters, sorts, and custom columns changed and releases every server-side table it made when closed.

Each instance has one owner which closes it when done so the server can free its resources. For multiple owners with independent lifetimes, copy() produces a distinct ResolvedTable instance referencing the same server-side table.

To instead use a JsTable, invoke createMutableTable(), which will return a new JsTable based on this table, which can then have its filters, sorts, and custom columns changed without affecting this table.

  • Method Details

    • copy

      @JsMethod JsResolvedTable copy()
      A new instance over the same server-side table with its own lifetime, available immediately. The caller owns it, and either instance can be closed without affecting the other.
      Returns:
      a new instance of this table, sharing resources on the server
      Throws:
      IllegalStateException - if this table is closed
    • createMutableTable

      @JsMethod JsTable createMutableTable()
      A new JsTable over the same server-side table, the inverse of JsTable.operations(). The JsTable can be changed with applyFilter, applySort and its other mutating methods without affecting this table, and the two are closed independently. Like other tables made by operations, it is not revived if a reconnect needs a new session.
      Returns:
      a new mutable table, which the caller must close
    • seekRow

      @JsMethod elemental2.promise.Promise<Double> seekRow(SeekRowOptions options)
      Finds the next row, after startingRow and wrapping around, whose value in column matches seekValue.
      Parameters:
      options - the value to find, and where and how to search for it
      Returns:
      a promise of the position of the matching row, or -1 if no row matches
    • createTreeTable

      @JsMethod default elemental2.promise.Promise<JsTreeTable> createTreeTable(@TsTypeRef(JsTreeTableConfig.class) @TsTypeRef(JsTreeTableConfig.class) Object configObject)
      A promise of a new dh.TreeTable of this table. Each call to this method produces a new dh.TreeTable, which must have close() called on it when not in use.
      Parameters:
      configObject - specifies which column to use as the row ID, and which for parent ID, and how to handle rows with no parent
      Returns:
      a promise of dh.TreeTable
    • createRollup

      @JsMethod default elemental2.promise.Promise<JsTreeTable> createRollup(@TsTypeRef(JsRollupConfig.class) @TsTypeRef(JsRollupConfig.class) Object configObject)
      A promise of a new roll-up dh.TreeTable of this table. Each call to this method produces a new dh.TreeTable, which must have close() called on it when not in use.
      Parameters:
      configObject - specifies which columns to aggregate and which to group by, and other rollup behavior
      Returns:
      a promise of dh.TreeTable