Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

alma::acsplugins::alarmsystem::gui::table::AlarmTable Class Reference

Collaboration diagram for alma::acsplugins::alarmsystem::gui::table::AlarmTable:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 AlarmTable (AlarmTableModel model)
Component prepareRenderer (TableCellRenderer renderer, int rowIndex, int vColIndex)
void actionPerformed (ActionEvent e)
void saveAlarm (Alarm alarm)
void close ()
void showColumns (AlarmTableColumn[] cols)
void addRemoveColumn (AlarmTableColumn col, boolean add)

Static Public Attributes

final JLabel reductionRenderer
final JLabel hasReducedNodesRenderer

Private Member Functions

void initialize ()
void buildPopupMenu ()
void colorizeCell (Component c, Alarm alarm)
void showReductionChain (Alarm alarm)

Private Attributes

AlarmTableModel model
TableRowSorter< TableModel > sorter
TableColumn[] columns
AlarmTableMouseAdapter mouseAdapter = new AlarmTableMouseAdapter()
ClipboardHelper clipboard = new ClipboardHelper()
JPopupMenu popupM = new JPopupMenu("Alarm")
JMenuItem ackMI = new JMenuItem("Acknowledge")
JMenuItem saveMI = new JMenuItem("Save...")
JMenuItem clipMI = new JMenuItem("To clipboard")
JMenuItem showReducedMI = new JMenuItem("Show reduction chain")
JLabel emptyLbl = new JLabel()
ReducedChainDlg reducedDlg = null

Detailed Description

The table of alarms


Constructor & Destructor Documentation

alma::acsplugins::alarmsystem::gui::table::AlarmTable::AlarmTable AlarmTableModel  model  )  [inline]
 

Constructor

Parameters:
model The model for this table


Member Function Documentation

void alma::acsplugins::alarmsystem::gui::table::AlarmTable::actionPerformed ActionEvent  e  )  [inline]
 

See also:
ActionListener

void alma::acsplugins::alarmsystem::gui::table::AlarmTable::addRemoveColumn AlarmTableColumn  col,
boolean  add
[inline]
 

Add/remove one column from the table

Parameters:
col The column to add or remove
add If true add the column, otherwise remove the column

void alma::acsplugins::alarmsystem::gui::table::AlarmTable::buildPopupMenu  )  [inline, private]
 

Build the popup menu

void alma::acsplugins::alarmsystem::gui::table::AlarmTable::close  )  [inline]
 

Free all the resource

void alma::acsplugins::alarmsystem::gui::table::AlarmTable::colorizeCell Component  c,
Alarm  alarm
[inline, private]
 

Set the background and the foreground of the component depending on the priority and the state of the passed alarm

Parameters:
c The component to color
priority The alarm to set the color

void alma::acsplugins::alarmsystem::gui::table::AlarmTable::initialize  )  [inline, private]
 

Init the GUI

Component alma::acsplugins::alarmsystem::gui::table::AlarmTable::prepareRenderer TableCellRenderer  renderer,
int  rowIndex,
int  vColIndex
[inline]
 

See also:
JTable

void alma::acsplugins::alarmsystem::gui::table::AlarmTable::saveAlarm Alarm  alarm  )  [inline]
 

Save the alarm in a file

Parameters:
The alarm to save in a plain text file

void alma::acsplugins::alarmsystem::gui::table::AlarmTable::showColumns AlarmTableColumn[]  cols  )  [inline]
 

Set the visible columns in the table. The columns are displayed following their order in the array.

Parameters:
cols The visible columns in the table; it can't be null and at least one column must be in the array.

void alma::acsplugins::alarmsystem::gui::table::AlarmTable::showReductionChain Alarm  alarm  )  [inline, private]
 

Show the dialog with all the nodes reduced by the passed alarm

Parameters:
alarm The alarm whose children must be shown in a dialog


Member Data Documentation

JMenuItem alma::acsplugins::alarmsystem::gui::table::AlarmTable::ackMI = new JMenuItem("Acknowledge") [private]
 

The menu item to acknowledge an alarm

ClipboardHelper alma::acsplugins::alarmsystem::gui::table::AlarmTable::clipboard = new ClipboardHelper() [private]
 

The clipboard

JMenuItem alma::acsplugins::alarmsystem::gui::table::AlarmTable::clipMI = new JMenuItem("To clipboard") [private]
 

The menu item to svae the selected alarm into the clipboard

TableColumn [] alma::acsplugins::alarmsystem::gui::table::AlarmTable::columns [private]
 

The cols of the table

JLabel alma::acsplugins::alarmsystem::gui::table::AlarmTable::emptyLbl = new JLabel() [private]
 

The label returned as renderer when no flag is shown in the first column of the table

final JLabel alma::acsplugins::alarmsystem::gui::table::AlarmTable::hasReducedNodesRenderer [static]
 

Initial value:

new JLabel( new ImageIcon(AlarmGUIType.class.getResource(AlarmGUIType.iconFolder+"add.png")), JLabel.CENTER)
The renderer for a node that hides children because of a reduction rule is in place

AlarmTableModel alma::acsplugins::alarmsystem::gui::table::AlarmTable::model [private]
 

The model of the table

AlarmTableMouseAdapter alma::acsplugins::alarmsystem::gui::table::AlarmTable::mouseAdapter = new AlarmTableMouseAdapter() [private]
 

The alarm adapter that recives events from the mouse

JPopupMenu alma::acsplugins::alarmsystem::gui::table::AlarmTable::popupM = new JPopupMenu("Alarm") [private]
 

The popup menu shown when the user presses the right mouse button over a row

ReducedChainDlg alma::acsplugins::alarmsystem::gui::table::AlarmTable::reducedDlg = null [private]
 

The dialog showing the table with the alarms involved in a reduction chain

final JLabel alma::acsplugins::alarmsystem::gui::table::AlarmTable::reductionRenderer [static]
 

Initial value:

new JLabel( new ImageIcon(AlarmGUIType.class.getResource(AlarmGUIType.iconFolder+"arrow_in.png")), JLabel.CENTER)
The renderer for the reduced alarm entries i.e. the entries normally hidden

JMenuItem alma::acsplugins::alarmsystem::gui::table::AlarmTable::saveMI = new JMenuItem("Save...") [private]
 

The menu item to save

JMenuItem alma::acsplugins::alarmsystem::gui::table::AlarmTable::showReducedMI = new JMenuItem("Show reduction chain") [private]
 

The menu to show the reduction chain of an alarm

TableRowSorter<TableModel> alma::acsplugins::alarmsystem::gui::table::AlarmTable::sorter [private]
 

The sorter for sorting the rows of the table


The documentation for this class was generated from the following file:
Generated on Thu Apr 30 03:00:37 2009 for ACS Java API by doxygen 1.3.8