|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.fife.rtext.plugins.tools.ToolManager
Manages the tools available in an RText session.
| Field Summary | |
static java.lang.String |
PROPERTY_TOOLS
Event fired when a tool is added or removed. |
| Method Summary | |
void |
addPropertyChangeListener(java.lang.String property,
java.beans.PropertyChangeListener l)
Adds a property change listener to this tool manager. |
void |
addTool(Tool tool)
Adds a tool. |
void |
clearTools()
Removes all tools from this manager. |
boolean |
containsToolWithName(java.lang.String name)
Returns whether a tool with a given name is already defined. |
static ToolManager |
get()
Returns the singleton instance of the tool manager. |
int |
getToolCount()
returns the number of tools. |
java.util.Iterator |
getToolIterator()
Returns an iterator over the tools. |
void |
loadTools(java.io.File dir)
Loads all tools from a directory. |
void |
removePropertyChangeListener(java.lang.String property,
java.beans.PropertyChangeListener l)
Removes a property change listener from this tool manager. |
void |
removeTool(Tool tool)
Removes a tool. |
void |
saveTools(java.io.File dir)
Saves all tools known to this tool manager. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final java.lang.String PROPERTY_TOOLS
| Method Detail |
public void addTool(Tool tool)
PROPERTY_TOOLS.
tool - The tool to add.removeTool(Tool)
public void addPropertyChangeListener(java.lang.String property,
java.beans.PropertyChangeListener l)
property - The property to listen for.l - The listener.removePropertyChangeListener(String, PropertyChangeListener)public void clearTools()
PROPERTY_TOOLS.
public boolean containsToolWithName(java.lang.String name)
name - The name of the tool.
public static ToolManager get()
public int getToolCount()
public java.util.Iterator getToolIterator()
public void loadTools(java.io.File dir)
throws java.io.IOException
dir - The directory to load tools from.
java.io.IOException - If an IO error occurs reading the tools.saveTools(File)
public void removePropertyChangeListener(java.lang.String property,
java.beans.PropertyChangeListener l)
property - The property listened for.l - The listener to remove.addPropertyChangeListener(String, PropertyChangeListener)public void removeTool(Tool tool)
PROPERTY_TOOLS.
tool - The tool to remove.addTool(Tool)
public void saveTools(java.io.File dir)
throws java.io.IOException
dir - The directory to save the tool definitions to. The old
contents of this directory are deleted.
java.io.IOException - If an IO error occurs writing the files.loadTools(File)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||