org.acm.seguin.ide.common
Class SourceBrowserAdapter

java.lang.Object
  extended by org.acm.seguin.ide.common.SourceBrowserAdapter
All Implemented Interfaces:
java.awt.event.ActionListener, java.util.EventListener

public class SourceBrowserAdapter
extends java.lang.Object
implements java.awt.event.ActionListener

Generic adapter for browsing source code

Author:
Chris Seguin

Constructor Summary
SourceBrowserAdapter(ISourceful component)
          Constructor for the SourceBrowserAdapter object
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent evt)
          Responds to this item being selected
protected  java.io.File findFile()
          Look up the chain of Summary parents to find the File the activeComponent is sourced in.
protected  int getLine()
          Get the line number of the start of the current activeComponent.
protected  Summary getSummary()
          Get the Summary of the activeComponent.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SourceBrowserAdapter

public SourceBrowserAdapter(ISourceful component)
Constructor for the SourceBrowserAdapter object

Parameters:
component - Description of Parameter
Method Detail

getLine

protected int getLine()
Get the line number of the start of the current activeComponent.

Returns:
The line number.

getSummary

protected Summary getSummary()
Get the Summary of the activeComponent.

Returns:
The Summary of the activeComponent.

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent evt)
Responds to this item being selected

Specified by:
actionPerformed in interface java.awt.event.ActionListener
Parameters:
evt - Description of Parameter

findFile

protected java.io.File findFile()
Look up the chain of Summary parents to find the File the activeComponent is sourced in.

Returns:
The File.