alma::acs::logging::errorbrowser::ErrorBrowserDlg Class Reference

Inheritance diagram for alma::acs::logging::errorbrowser::ErrorBrowserDlg:
Inheritance graph
[legend]
Collaboration diagram for alma::acs::logging::errorbrowser::ErrorBrowserDlg:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ErrorBrowserDlg (LoggingClient client)
synchronized void addErrorTab (final LogEntryTableModelBase sourceModel, final String stackId)
void close ()
void setVisible (boolean visible)
void componentAdded (ContainerEvent e)
void componentRemoved (ContainerEvent e)

Private Member Functions

void initialize ()
void removeDuplicatedTabs (final String tabTitle)
void ratioContent ()

Private Attributes

final JTabbedPane tabbedPane = new JTabbedPane()
final JPanel notTracesPnl = new JPanel(new BorderLayout())
final LoggingClient loggingClient
final CardLayout cardLayout = new CardLayout()
final JPanel cardsPanel = new JPanel(cardLayout)

Static Private Attributes

static final String NO_ERROR_TRACES = "Empty"
static final String ERROR_TRACES = "ErrorTraces"

Detailed Description

The dialog showing the stack trace of errors.

The dialog has one tab for each stack trace whose title is the stack ID.

Author:
acaproni

Constructor & Destructor Documentation

alma::acs::logging::errorbrowser::ErrorBrowserDlg::ErrorBrowserDlg ( LoggingClient  client  )  [inline]

Constructor

Parameters:
client A not null reference to the LoggingClient

References initialize(), and loggingClient.


Member Function Documentation

synchronized void alma::acs::logging::errorbrowser::ErrorBrowserDlg::addErrorTab ( final LogEntryTableModelBase  sourceModel,
final String  stackId 
) [inline]

Add a new error tab.

The tab is added by a separate thread.

Parameters:
sourceModel The model used by the Engine to look for logs belonging to the error trace with the give STACKID
stackId The STACKID of logs of the stack trace

References removeDuplicatedTabs(), setVisible(), and tabbedPane.

Referenced by com::cosylab::logging::LoggingClient::addErrorTab().

void alma::acs::logging::errorbrowser::ErrorBrowserDlg::close (  )  [inline]
void alma::acs::logging::errorbrowser::ErrorBrowserDlg::componentAdded ( ContainerEvent  e  )  [inline]
See also:
ContainerListener

References ratioContent().

void alma::acs::logging::errorbrowser::ErrorBrowserDlg::componentRemoved ( ContainerEvent  e  )  [inline]
See also:
ContainerListener

References ratioContent().

void alma::acs::logging::errorbrowser::ErrorBrowserDlg::initialize (  )  [inline, private]

Init the GUI.

The dialog is composed of a set of tabs, one for each stack trace.

References cardsPanel, ERROR_TRACES, NO_ERROR_TRACES, notTracesPnl, ratioContent(), setVisible(), and tabbedPane.

Referenced by ErrorBrowserDlg().

void alma::acs::logging::errorbrowser::ErrorBrowserDlg::ratioContent (  )  [inline, private]

Shown the proper content in the dialog:

  • the label when there are no error traces
  • the tabbed pane when there is at least one error trace

References cardLayout, cardsPanel, ERROR_TRACES, NO_ERROR_TRACES, and tabbedPane.

Referenced by componentAdded(), componentRemoved(), and initialize().

void alma::acs::logging::errorbrowser::ErrorBrowserDlg::removeDuplicatedTabs ( final String  tabTitle  )  [inline, private]

Remove all the tabs with the given title, if any.

The removal runs synchronously inside the vent dispatcher EDT.

Parameters:
title The title of the tab

References tabbedPane.

Referenced by addErrorTab().

void alma::acs::logging::errorbrowser::ErrorBrowserDlg::setVisible ( boolean  visible  )  [inline]

Override setVisible() to move the dialog over the logging client and in front of other windows

References loggingClient.

Referenced by com::cosylab::logging::LoggingClient::EventHandler::actionPerformed(), addErrorTab(), close(), and initialize().


Member Data Documentation

final CardLayout alma::acs::logging::errorbrowser::ErrorBrowserDlg::cardLayout = new CardLayout() [private]

The CardLayout shows the tabbed pane when the dialog contains error traces and a label when no error traces have been defined.

Referenced by ratioContent().

The panel with the variable content.

The components shown by the panel is defined by the card layout.

Referenced by initialize(), and ratioContent().

final String alma::acs::logging::errorbrowser::ErrorBrowserDlg::ERROR_TRACES = "ErrorTraces" [static, private]

The name of the card shown when there are no error traces

Referenced by initialize(), and ratioContent().

The logging client

Referenced by ErrorBrowserDlg(), and setVisible().

The name of the card shown when there are no error traces

Referenced by initialize(), and ratioContent().

final JPanel alma::acs::logging::errorbrowser::ErrorBrowserDlg::notTracesPnl = new JPanel(new BorderLayout()) [private]

The panel shown when the dialog is displayed with no error traces.

Referenced by initialize().

final JTabbedPane alma::acs::logging::errorbrowser::ErrorBrowserDlg::tabbedPane = new JTabbedPane() [private]

The pane showing the error tabs

Referenced by addErrorTab(), close(), initialize(), ratioContent(), and removeDuplicatedTabs().


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

Generated by  doxygen 1.6.2