Tables
This content needs to be reviewed. Tables have recently been enabled by copying TSTool code.
Introduction
StateDMI provides features to automate processing tabular data and tables are a "first class" data object in StateDMI, managed by the processor. Tables have identifiers that are used to retrieve and save tables to the processor.
Table Design
Tables use a custom
DataTable
utility class in the
Table
package.
This package was originally developed at a time when third-party table packages were lacking and it would
require some effort to replace the existing code.
Table functionality was originally developed to store spatial data shape attributes and was later
enhanced to support reading data from datastores, Excel files, delimited files, etc.
The DataTable
code design is fairly simple, consisting of the following:
- List of
DataTableField
to provide table column metadata - List of
TableRecord
to manage table rows - Other related classes
Data included in tables are expected to extend from the Java Object
class and null values are allowed.
The table therefore consists of a list of lists (list of
TableRecord
,
which is list of column object values).
This design could be optimized but works relatively well.
If memory is an issue, the FreeTable
command can be used.