Creates a new controller for a table with the given numer of columns.
the columns as a list of pairs of column key and column label. Labels may be functions which are invoked with the table controller as this and the key as argument if a label is required.
the initial sort key
the initial sort order
This method sets the primary sort key. If the order is
undefined
, and the current sort key is the same as the
specified key, the current sort order is inverted.
the column key
Optional
order: stringthe sort order ('up' for ascending
and 'down' for descending) or undefined
A generic controller for tables. It provides information about the available columns and maintains state regarding their sort order and direction. In addition, it supports simple filtering based on cell content.