Table is an immutable 2-dimensional Map, containing row keys and column keys, where a combination of a row and column key can contain one value.
The Table structure is useful in cases where there are two properties that in combination have some value. For example, a school with students needs to store a grade for each class the student takes. The school is only interested in the last grade. In this case, a Table with the student as row key, the class as column key, and the grade as value would allow easy access to all the grades.
Table<R, C, V> is built on:
RMap<R, RMap<C, V>>. So it is a Map of Maps. The
.rowMap property gives direct access to this Map, and can sometimes provide more convenient ways to access the contained data.
@rimbu/core package exports the following abstract Table TypeScript types:
|a type-variant |
|a generic |
@rimbu/core package exports the following concrete Table types: