org.pf.joi
Class BasicInspector

java.lang.Object
  extended by java.awt.event.MouseAdapter
      extended by org.pf.joi.Inspector
          extended by org.pf.joi.BasicInspector
All Implemented Interfaces:
java.awt.event.ActionListener, java.awt.event.MouseListener, java.util.EventListener, javax.swing.event.TreeSelectionListener
Direct Known Subclasses:
AssociationListInspector, DynamicProxyInspector, KeyValueInspector, ListInspector, StringInspector

public class BasicInspector
extends Inspector
implements java.awt.event.ActionListener, javax.swing.event.TreeSelectionListener

This is the default inspector, which can display all normal java objects. Currently it opens a window on the object to inspect and displays all of its fields that are not static and not final, which means no class variables and no constants, but all instance variables (including inherited attributes).
For arrays it lists up all elements from 0 to n.
For deeper inspection it is possible to open a new inspector on each attribute.

Here is an example how to use the inspector:

Since:
JDK 1.2
Version:
1.2
Author:
Manfred Duchrow

Field Summary
 
Fields inherited from class org.pf.joi.Inspector
EXPORTER_MAPPING_FILENAME, EXPORTER_MAPPING_FILENAME_ALL, EXPORTER_MAPPING_FILENAME_CLASSLOADER, INSPECTOR_MAPPING_FILENAME, INSPECTOR_MAPPING_FILENAME_ALL, INSPECTOR_MAPPING_FILENAME_CLASSLOADER
 
Constructor Summary
BasicInspector()
          Initialize the new instance with default values.
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent e)
          Is called whenever a user action event occured.
 void mouseClicked(java.awt.event.MouseEvent e)
          This method is called for every mouse click in the tree component.
 void valueChanged(javax.swing.event.TreeSelectionEvent event)
          Is called whenever the selection in the element tree changed.
 
Methods inherited from class org.pf.joi.Inspector
basicInspect, basicInspect, basicInspectWait, basicInspectWait, bindInspector, deactivateHalt, fullIdentification, getBasicObjectSpy, getBasicObjectSpy, getObjectSpy, getObjectSpy, getProgSignature, halt, inspect, inspect, inspectWait, inspectWait, main, shortIdentification
 
Methods inherited from class java.awt.event.MouseAdapter
mouseEntered, mouseExited, mousePressed, mouseReleased
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BasicInspector

public BasicInspector()
Initialize the new instance with default values.

Method Detail

valueChanged

public void valueChanged(javax.swing.event.TreeSelectionEvent event)
Is called whenever the selection in the element tree changed.
It updates the information in the right section of the inspector window.

Specified by:
valueChanged in interface javax.swing.event.TreeSelectionListener
See Also:
TreeSelectionListener

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent e)
Is called whenever a user action event occured.
This method is actually performing all actions, triggered by buttons, keystrokes or menu items.

Specified by:
actionPerformed in interface java.awt.event.ActionListener
Parameters:
e - The action event holding further information on what happened.

mouseClicked

public void mouseClicked(java.awt.event.MouseEvent e)
This method is called for every mouse click in the tree component.
It brings up the popup menu for context specific actions.

Specified by:
mouseClicked in interface java.awt.event.MouseListener
Overrides:
mouseClicked in class java.awt.event.MouseAdapter