public interface Tool
To be loaded in jGRASP, tool class names must end in "Tool". Supporting class names should not end in "Tool".
Modifier and Type | Method and Description |
---|---|
void |
applyConditions(Conditions conditions)
Applies current conditions.
|
void |
closeWindows()
Closes any open windows associated with the tool (not including
settings).
|
ToolState |
createState()
Creates an instance of the tool state.
|
void |
fileRemoved(Conditions conditions,
File fl,
boolean isTest)
Indicates that a file was removed from a project.
|
String |
getClasspath()
Gets the classpath, if any, needed for documentation of test files.
|
String |
getDataId()
Gets an identifier to be used as a key when storing tool data.
|
String |
getMenuName()
Gets the name of the menu for this tool, which will appear in the jGRASP
"Tools" menu when appropriate.
|
ResizableFlexWidthIcon |
getStateIcon(ProjectState ps,
File fl,
boolean getSpacer)
Gets an icon that indicates the state of a file in a project.
|
ToolAction[] |
getToolActions()
Gets the actions that the tool provides.
|
void applyConditions(Conditions conditions)
conditions
- the new conditions.void closeWindows()
ToolState createState()
void fileRemoved(Conditions conditions, File fl, boolean isTest)
conditions
- conditions containing project info.fl
- file to be removed.isTest
- true if the file is a test file, false otherwise.String getClasspath()
String getDataId()
String getMenuName()
ResizableFlexWidthIcon getStateIcon(ProjectState ps, File fl, boolean getSpacer)
ps
- project state to which the icon applies.fl
- file to which the icon applies.getSpacer
- if true, an invisible icon with the same width-to-height
computations as the other state icons will be returned.ToolAction[] getToolActions()