alma::acs::logging::table::LogTableRowSorter Class Reference

Inheritance diagram for alma::acs::logging::table::LogTableRowSorter:
Inheritance graph
[legend]
Collaboration diagram for alma::acs::logging::table::LogTableRowSorter:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 LogTableRowSorter (LogTableDataModel model)
void setFilters (FiltersVector newFilters, boolean append)
String getFiltersString ()
FiltersVector getFilters ()
void setLogLevel (LogTypeHelper newLevel)
void toggleSortOrder (int column)
void run ()

Private Member Functions

void applyChanges ()

Private Attributes

final FiltersVector filters = new FiltersVector()
LogTypeHelper logLevel = LogTypeHelper.TRACE
int col

Detailed Description

LogTableRowSorter extends TableRowSorter to customize ordering, sorting and filtering for the table of logs.

The engine and the FilterChooserDialog uses a FiltersVector to apply filtering to the logs but JTable needs a RowSorter instead.
This object converts the engine specific vector of filters into the objects expected by the table.

Author:
acaproni

Constructor & Destructor Documentation

alma::acs::logging::table::LogTableRowSorter::LogTableRowSorter ( LogTableDataModel  model  )  [inline]

References applyChanges().


Member Function Documentation

void alma::acs::logging::table::LogTableRowSorter::applyChanges (  )  [inline, private]

Set a new filter forcing a reordering of the table

References filters, logLevel, and run().

Referenced by LogTableRowSorter(), setFilters(), and setLogLevel().

FiltersVector alma::acs::logging::table::LogTableRowSorter::getFilters (  )  [inline]

Return the filters defined by the user

Returns:
The user defined filters

Implements com::cosylab::logging::engine::Filterable.

References filters.

Referenced by alma::acs::logging::table::LogEntryTable::getFilters().

String alma::acs::logging::table::LogTableRowSorter::getFiltersString (  )  [inline]
void alma::acs::logging::table::LogTableRowSorter::run (  )  [inline]

The thread to execute the super.toggleSortOrder without freezing the GUI.

References col.

Referenced by applyChanges().

void alma::acs::logging::table::LogTableRowSorter::setFilters ( FiltersVector  newFilters,
boolean  append 
) [inline]

Set the filters. The new filters can replace or appended to the already exisiting filters.

The new filters can be null to remove the filtering. For this purpose append must be false.

Parameters:
newFilters The new vector of filters It can be null to remove the filtering
append If true the filters are appended to the existing filters

Implements com::cosylab::logging::engine::Filterable.

References com::cosylab::logging::engine::FiltersVector::addFilter(), applyChanges(), com::cosylab::logging::engine::FiltersVector::clear(), filters, com::cosylab::logging::engine::FiltersVector::isActive(), and com::cosylab::logging::engine::FiltersVector::setFilters().

Referenced by alma::acs::logging::table::LogEntryTable::setFilters().

void alma::acs::logging::table::LogTableRowSorter::setLogLevel ( LogTypeHelper  newLevel  )  [inline]

Set the new log level i.e. the level of the logs shown in the table.

Parameters:
newLevel 

References applyChanges(), and logLevel.

Referenced by alma::acs::logging::table::LogEntryTable::setLogLevel().

void alma::acs::logging::table::LogTableRowSorter::toggleSortOrder ( int  column  )  [inline]

Change the ordering when the user presses over a column header. We need to execute this method on a separate thread otherwise the GUI freezes until the ordering completes.

References col.


Member Data Documentation

The column for the toggleSortOrder that must be executed in a separate thread toggleSortOrder

See also:

Referenced by run(), and toggleSortOrder().

The filters

Referenced by applyChanges(), getFilters(), getFiltersString(), and setFilters().

LogTypeHelper alma::acs::logging::table::LogTableRowSorter::logLevel = LogTypeHelper.TRACE [private]

The log level

Parameters:
model 

Referenced by applyChanges(), and setLogLevel().


The documentation for this class was generated from the following file:

Generated by  doxygen 1.6.2