|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.bluemarsh.jswat.panel.JSwatPanel | +--com.bluemarsh.jswat.panel.WatchPanel
Class WatchPanel watches the modification events of variables and displays the changed values in a table.
This works by maintaining a blank row in the watch table for the user to add new watchpoints. That is, the user will type the name of a variable to watch into the blank row. To remove a watchpoint, the user must clear the name from that row.
Inner Class Summary | |
protected class |
WatchPanel.WatchpointListEntry
Class WatchpointListEntry represents any type of watchpoint the user has specified. |
Field Summary | |
protected Session |
session
Reference to the session. |
protected javax.swing.JTable |
table
Table displaying the threads. |
protected javax.swing.JScrollPane |
uicomp
Our UI component - scrollable panel |
protected java.util.List |
watchpointList
List of the existing watchpoint requests. |
Fields inherited from class com.bluemarsh.jswat.panel.JSwatPanel |
swat |
Fields inherited from interface com.bluemarsh.jswat.event.VMEventListener |
PRIORITY_BREAKPOINT, PRIORITY_DEFAULT, PRIORITY_HIGH, PRIORITY_HIGHEST, PRIORITY_LOW, PRIORITY_LOWEST, PRIORITY_SESSION |
Constructor Summary | |
WatchPanel()
Constructs a WatchPanel with the default table. |
Method Summary | |
void |
activate(Session session)
Called when the Session is about to begin an active debugging session. |
protected int |
addBlankRow()
Adds the blank row to the model, to allow entry of a new watchpoint. |
protected void |
addWatchpoint(java.lang.String expr,
int row,
boolean addBlank)
Add the named variable to the watch list. |
void |
contextChanged(ContextChangeEvent cce)
Invoked when the current context has changed. |
void |
deactivate(Session session)
Called when the Session is about to end an active debugging session. |
boolean |
eventOccurred(com.sun.jdi.event.Event e)
Invoked when a VM event has occurred. |
javax.swing.JComponent |
getPeer()
Returns a reference to the peer UI component. |
javax.swing.JComponent |
getUI()
Returns a reference to the UI component. |
void |
refresh(Session session)
Update the display on the screen. |
protected void |
resolveWatchpoint(int row,
WatchPanel.WatchpointListEntry entry)
Try to resolve a watchpoint. |
protected void |
resolveWatchpoints()
Iterate the list of watchpoints and try to resolve any unresolved entries. |
void |
tableChanged(javax.swing.event.TableModelEvent e)
Invoked whenever the table model changes. |
Methods inherited from class com.bluemarsh.jswat.panel.JSwatPanel |
close, init |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected javax.swing.JTable table
protected javax.swing.JScrollPane uicomp
protected Session session
protected java.util.List watchpointList
Constructor Detail |
public WatchPanel()
Method Detail |
public void activate(Session session)
activate
in class JSwatPanel
session
- Session being activated.protected int addBlankRow()
protected void addWatchpoint(java.lang.String expr, int row, boolean addBlank)
expr
- name of variable to watch.row
- row to add to.addBlank
- true to add a blank row as needed.public void contextChanged(ContextChangeEvent cce)
contextChanged
in interface ContextListener
cce
- context change eventpublic void deactivate(Session session)
deactivate
in class JSwatPanel
session
- Session being deactivated.public boolean eventOccurred(com.sun.jdi.event.Event e)
eventOccurred
in interface VMEventListener
e
- VM eventpublic javax.swing.JComponent getPeer()
public javax.swing.JComponent getUI()
getUI
in class JSwatPanel
public void refresh(Session session)
refresh
in class JSwatPanel
session
- Debugging Session object.protected void resolveWatchpoint(int row, WatchPanel.WatchpointListEntry entry)
row
- row number in table.entry
- watchpoint list entry.protected void resolveWatchpoints()
public void tableChanged(javax.swing.event.TableModelEvent e)
tableChanged
in interface javax.swing.event.TableModelListener
e
- Table model event.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |