Class JsInputTable
java.lang.Object
io.deephaven.web.client.api.input.JsInputTable
A js type for operating on input tables.
Represents a User Input Table, which can have data added to it from other sources.
You may add rows using dictionaries of key-value tuples (representing columns by name), add tables containing all the
key/value columns to add, or delete tables containing the keys to delete. Each operation is atomic, and will either
succeed completely or fail completely. To guarantee order of operations, apply an operation and wait for the response
before sending the next operation.
Each table has one or more key columns, where each unique combination of keys will appear at most once in the table.
To view the results of the Input Table, you should use standard table operations on the InputTable's source Table
object.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionelemental2.promise.Promise<JsInputTable>
Adds a single row to the table.elemental2.promise.Promise<JsInputTable>
Add multiple rows to a table.elemental2.promise.Promise<JsInputTable>
Add an entire table to this Input Table.elemental2.promise.Promise<JsInputTable>
Add multiple tables to this Input Table.elemental2.promise.Promise<JsInputTable>
deleteTable
(JsTable tableToDelete) Deletes an entire table from this Input Table.elemental2.promise.Promise<JsInputTable>
deleteTables
(JsTable[] tablesToDelete) Delete multiple tables from this Input Table.Column[]
A list of the key columns.String[]
getKeys()
A list of the key columns, by namegetTable()
The source table for this Input TableColumn[]
A list of the value Column objectsString[]
A list of the value columns, by name
-
Constructor Details
-
JsInputTable
-
-
Method Details
-
getKeys
A list of the key columns, by name- Returns:
- String array.
-
getKeyColumns
A list of the key columns.- Returns:
- Column array.
-
getValues
A list of the value columns, by name- Returns:
- String array.
-
getValueColumns
A list of the value Column objects- Returns:
Column
array.
-
addRow
public elemental2.promise.Promise<JsInputTable> addRow(jsinterop.base.JsPropertyMap<?> row, @JsOptional String userTimeZone) Adds a single row to the table. For each key or value column name in the Input Table, we retrieve that javascript property at that name and validate it can be put into the given column type.- Parameters:
row
-userTimeZone
-- Returns:
- Promise of dh.InputTable
-
addRows
public elemental2.promise.Promise<JsInputTable> addRows(jsinterop.base.JsPropertyMap<?>[] rows, @JsOptional String userTimeZone) Add multiple rows to a table.- Parameters:
rows
-userTimeZone
-- Returns:
- Promise of dh.InputTable
-
addTable
Add an entire table to this Input Table. Only column names that match the definition of the input table will be copied, and all key columns must have values filled in. This only copies the current state of the source table; future updates to the source table will not be reflected in the Input Table. The returned promise will be resolved to the same InputTable instance this method was called upon once the server returns.- Parameters:
tableToAdd
-- Returns:
- Promise of dh.InputTable
-
addTables
Add multiple tables to this Input Table.- Parameters:
tablesToAdd
-- Returns:
- Promise of dh.InputTable
-
deleteTable
Deletes an entire table from this Input Table. Key columns must match the Input Table.- Parameters:
tableToDelete
-- Returns:
- Promise of dh.InputTable
-
deleteTables
Delete multiple tables from this Input Table.- Parameters:
tablesToDelete
-- Returns:
-
getTable
The source table for this Input Table- Returns:
- dh.table
-