|
|||||||||
| Home >> All >> evt >> [ gui overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
evt.gui
Class JspmEventPanel

java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
evt.gui.JspmEventPanel
- All Implemented Interfaces:
- javax.accessibility.Accessible, java.util.EventListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.awt.event.MouseListener, java.lang.Runnable, java.io.Serializable
- public class JspmEventPanel
- extends javax.swing.JPanel
- implements java.lang.Runnable, java.awt.event.MouseListener
- extends javax.swing.JPanel
JSPM Event panel. This panel defines the actual event list panel.
- Version:
- 0.0.8
| Nested Class Summary | |
class |
JspmEventPanel.JspmEvtEventMenu
|
class |
JspmEventPanel.JspmEvtHeldMenu
|
| Nested classes inherited from class javax.swing.JPanel |
javax.swing.JPanel.AccessibleJPanel |
| Nested classes inherited from class javax.swing.JComponent |
javax.swing.JComponent.AccessibleJComponent |
| Nested classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
| Nested classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
| Field Summary | |
private boolean |
autoScroll
|
(package private) java.sql.Connection |
con
The SQL connection. |
private int |
currentDay
|
private int |
currentId
Some general counters |
private int |
eventCount
|
private javax.swing.JScrollPane |
eventList
The scrollpanel for the table |
private javax.swing.JTable |
eventTable
The event tables |
private javax.swing.table.DefaultTableModel |
eventTableModel
Data table model for the event table |
private JspmEvtTableCellRenderer |
eventTableRenderer
The default table cell renderer |
private boolean |
hasSendkeep
|
private javax.swing.JScrollPane |
heldList
The scrollpanel for the table |
private javax.swing.JTable |
heldTable
|
private javax.swing.table.DefaultTableModel |
heldTableModel
|
private JspmEvtTableCellRenderer |
heldTableRenderer
|
private boolean |
initialized
Processing flags |
private JspmEvtDb |
jsmEvtDb
The database connection |
private javax.swing.JSplitPane |
jsmSplitPane
The split pane, for the event and held areas. |
private com.jdk.JspmLogWriter |
logWriter
The JSPM log writer |
private boolean |
online
|
private boolean[] |
sevFilter
Severity filter array. |
private JspmEvtStatusPanel |
statusPanel
The status panel at the bottom of the GUI |
private static int |
updateInterval
The updateInterval in msec (default is 5sec.) |
| Fields inherited from class javax.swing.JComponent |
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Container |
|
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
JspmEventPanel(JspmEvtDb je,
JspmEvtStatusPanel st,
com.jdk.JspmLogWriter lw)
Constructor. |
|
| Method Summary | |
void |
backOneDay()
Scrolls back one day. |
void |
backToEnd()
Scrolls back to the beginning of the database |
void |
bottom()
Scrolls to the bottom of the list. |
private void |
checkHeld()
Check the held area. |
private boolean |
checkSeverityFilter(int severity)
Check the speicified severity against the severity filter and returns true if severity is selected, otherwise false. |
private javax.swing.JTable |
createEventTable()
Create the event table. |
private javax.swing.JTable |
createHeldTable()
Create the held table. |
void |
forwOneDay()
Scroll forward one day. |
void |
forwToDay()
Scrolls forward to the current day. |
void |
getAllEvents()
Gets all events from today. |
void |
getEvents()
Get all events |
boolean |
isAutoScroll()
Returns the current autoscroll setting. |
void |
mouseClicked(java.awt.event.MouseEvent e)
Mouse event callback. |
void |
mouseEntered(java.awt.event.MouseEvent e)
Mouse event callback. |
void |
mouseExited(java.awt.event.MouseEvent e)
Mouse event callback. |
void |
mousePressed(java.awt.event.MouseEvent e)
Mouse event callback. |
void |
mouseReleased(java.awt.event.MouseEvent e)
Mouse event callback. |
private void |
removeAllRows()
Removes all rows. |
void |
run()
Main loop. |
private void |
scrollToBottom()
Scrolls to the bottom of the list |
private void |
scrollToTop()
Scrolls to the top of the list |
private void |
setAck(int[] rows)
Sets the acknowledge bit and removed the message from the held area. |
void |
setFilter(boolean[] sevs)
Sets the severity filter |
void |
setHeld()
Creates the held area on demand. |
private javax.swing.ImageIcon |
sev2ico(int sev)
Returns the icon for the specified severity |
void |
startEvent()
Starts the event panel. |
void |
toggleAutoScroll()
Changes the auto scroll feature. |
void |
top()
Scrolls to the top of the list. |
void |
unsetHeld()
Removes the held area from the split pane. |
void |
updateData()
Updates the event panel by loading the new events. |
| Methods inherited from class javax.swing.JPanel |
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
logWriter
private com.jdk.JspmLogWriter logWriter
- The JSPM log writer
updateInterval
private static int updateInterval
- The updateInterval in msec (default is 5sec.)
jsmEvtDb
private JspmEvtDb jsmEvtDb
- The database connection
con
java.sql.Connection con
- The SQL connection.
eventList
private javax.swing.JScrollPane eventList
- The scrollpanel for the table
heldList
private javax.swing.JScrollPane heldList
- The scrollpanel for the table
eventTable
private javax.swing.JTable eventTable
- The event tables
heldTable
private javax.swing.JTable heldTable
eventTableModel
private javax.swing.table.DefaultTableModel eventTableModel
- Data table model for the event table
heldTableModel
private javax.swing.table.DefaultTableModel heldTableModel
eventTableRenderer
private JspmEvtTableCellRenderer eventTableRenderer
- The default table cell renderer
heldTableRenderer
private JspmEvtTableCellRenderer heldTableRenderer
initialized
private boolean initialized
- Processing flags
autoScroll
private boolean autoScroll
hasSendkeep
private boolean hasSendkeep
currentId
private int currentId
- Some general counters
currentDay
private int currentDay
eventCount
private int eventCount
online
private boolean online
sevFilter
private boolean[] sevFilter
- Severity filter array.
statusPanel
private JspmEvtStatusPanel statusPanel
- The status panel at the bottom of the GUI
jsmSplitPane
private javax.swing.JSplitPane jsmSplitPane
- The split pane, for the event and held areas.
| Constructor Detail |
JspmEventPanel
public JspmEventPanel(JspmEvtDb je, JspmEvtStatusPanel st, com.jdk.JspmLogWriter lw)
- Constructor.
| Method Detail |
setHeld
public void setHeld()
- Creates the held area on demand.
If no event are in the held area (all acknowledged) than the held area is removed from the
splitpane.
unsetHeld
public void unsetHeld()
- Removes the held area from the split pane.
checkHeld
private void checkHeld()
- Check the held area.
Checks whether there are still events in the held area. In case there are no more
events the held area is removed from the split pane.
createEventTable
private javax.swing.JTable createEventTable()
- Create the event table.
createHeldTable
private javax.swing.JTable createHeldTable()
- Create the held table.
removeAllRows
private void removeAllRows()
- Removes all rows.
Both tables are cleared.
sev2ico
private javax.swing.ImageIcon sev2ico(int sev)
- Returns the icon for the specified severity
getEvents
public void getEvents()
- Get all events
getAllEvents
public void getAllEvents()
- Gets all events from today.
updateData
public void updateData()
- Updates the event panel by loading the new events.
startEvent
public void startEvent()
- Starts the event panel. Update interval is per default 5sec.
scrollToBottom
private void scrollToBottom()
- Scrolls to the bottom of the list
scrollToTop
private void scrollToTop()
- Scrolls to the top of the list
run
public void run()
- Main loop. This loop will update the event panel every 5sec.
- Specified by:
runin interfacejava.lang.Runnable
isAutoScroll
public boolean isAutoScroll()
- Returns the current autoscroll setting.
backToEnd
public void backToEnd()
- Scrolls back to the beginning of the database
backOneDay
public void backOneDay()
- Scrolls back one day.
forwOneDay
public void forwOneDay()
- Scroll forward one day.
forwToDay
public void forwToDay()
- Scrolls forward to the current day.
top
public void top()
- Scrolls to the top of the list.
bottom
public void bottom()
- Scrolls to the bottom of the list.
toggleAutoScroll
public void toggleAutoScroll()
- Changes the auto scroll feature. If autoscroll is on it will switch it
off and vice versa.
setFilter
public void setFilter(boolean[] sevs)
- Sets the severity filter
checkSeverityFilter
private boolean checkSeverityFilter(int severity)
- Check the speicified severity against the severity filter
and returns true if severity is selected, otherwise
false.
setAck
private void setAck(int[] rows)
- Sets the acknowledge bit and removed the message from the held area.
mouseClicked
public void mouseClicked(java.awt.event.MouseEvent e)
- Mouse event callback.
- Specified by:
mouseClickedin interfacejava.awt.event.MouseListener
mousePressed
public void mousePressed(java.awt.event.MouseEvent e)
- Mouse event callback.
- Specified by:
mousePressedin interfacejava.awt.event.MouseListener
mouseReleased
public void mouseReleased(java.awt.event.MouseEvent e)
- Mouse event callback.
- Specified by:
mouseReleasedin interfacejava.awt.event.MouseListener
mouseEntered
public void mouseEntered(java.awt.event.MouseEvent e)
- Mouse event callback.
- Specified by:
mouseEnteredin interfacejava.awt.event.MouseListener
mouseExited
public void mouseExited(java.awt.event.MouseEvent e)
- Mouse event callback.
- Specified by:
mouseExitedin interfacejava.awt.event.MouseListener
|
|||||||||
| Home >> All >> evt >> [ gui overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC