| ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Interface IdeManager provides the entire IDE's fuctionality.
This interface supplies methods relating to the overall IDE functionality, such as saving the opened files or starting a
new process.
IdeManager provides a convenient mechanism for retrieving additional
information about the result of certain actions. This information is stored in the
IdeErrorInfo object accessible through the setErrorInfo
and performCheck methods.
Current IdeManager can be obtained via static
IdeManagerAccess.getManager method:
IdeManager manager = IdeManagerAccess.getManager();| Method Summary | |
void | addCommandAndWait(Runnable command)Adds ceratin command to the commands queue and waits while this command is not executed. |
void | addCommandToQueue(Runnable command)Adds specified command to the commands queue. |
void | addCommandToQueue(Runnable command, String name)Adds specified command, identified by it's name, to the commands queue. |
String | buildDiagramURL(RwiDiagram diagram, RwiElement element)Creates URL of a specific kind referring to the specified element of the diagram. |
String | buildEditorURL(String url, TextPosition position)Produces URL of a specific kind, referring to the position in a certain file. |
String | buildEditorURL(String url, int offset)Produces URL of a specific kind, referring to the offset in a certain file. |
Process | exec(String command)Executes specified command in a separate process. |
Process | exec(String command, String fileForOut)Executes the specified command in a separate process, with the specifed output file. |
String | expandMacros(IdeContext context, String command)Replaces macros in command with the corresponding values. |
String[] | getArguments()Returns the list of arguments passed to 'main' method. |
IdeCommandManager | getCommandManager()Deprecated. |
IdeConfigManager | getConfigManager()Deprecated. |
IdeDiagramManager | getDiagramManager()Deprecated. |
IdeEditorManager | getEditorManager()Deprecated. |
String | getHomeDirectory()Returns fully qualified path of Together's root directory. |
IdeMessageManager | getMessageManager()Deprecated. |
String | getModuleHomeDirectory(Class moduleClass)Returns home folder for the module, defined by it's class. |
IdeProgressIndicator | getProgressIndicator()Deprecated. |
IdeProjectManager | getProjectManager()Deprecated. |
String | getTempFile()Returns the name of a temporary file. |
Locale | getUILocale()Returns a locale object for the Together's User Interface. |
IdeUndoManager | getUndoManager()Deprecated. |
IdeWindowManager | getWindowManager()Deprecated. |
boolean | isGUIEnabled()Checks if Together works in GUI or in a command line mode. |
boolean | isModuleActive(String moduleClassName)Checks the state of the specified activatable module. |
boolean | isModuleServiceAvailable(String serviceName)Returns true if the service with the specified name
is declared by loaded module, false otherwise. |
void | navigateByURL(String url)Opens specified internal URL if its associated handler is visible on the screen. |
void | openApplicationHelp(String topic, Component parent)Opens help with JavaHelp reffered to by the specified topic. |
void | openHelp(String url)Deprecated. |
void | openURL(String url)Opens specified URL (Universe Resource Locator). |
IdeErrorInfo | performCheck(IdeErrorCheck check)Calls run() method of the specified IdeErrorCheck object and returns
IdeErrorInfo containing the information about possible errors that occurred. |
void | printStatus(String text)Displays the specified string in the status bar. |
void | saveAll()Saves all opened files which were changed by Together. |
void | setErrorInfo(IdeErrorInfo info)Sets specified result of certain actions. |
void | showHelp(String targetID, boolean openInModalDialog, Component parent)Deprecated. |
void | showHelp(java.net.URL url, boolean openInModalDialog, Component parent)Deprecated. |
void | synchronize()If the data of the opened files change on the disk, automatically reloads these files. |
| Method Detail |
public void addCommandAndWait(Runnable command)
Runnable object to be added to the queuepublic void addCommandToQueue(Runnable command)
command to the commands queue.Runnable object to be added to the queuepublic void addCommandToQueue(Runnable command, String name)
Runnable object to be added to the queueString name of this commandpublic String buildDiagramURL(RwiDiagram diagram, RwiElement element)
element of the diagram.RwiDiagram where this element is locatedRwiElement object representing the target elementString URL that contains information about the position of the specified elementpublic String buildEditorURL(String url, TextPosition position)
position in a certain file.
String URL of a fileTextPosition instanceString URL that contains information about the position in this file,
String initial URL otherwisepublic String buildEditorURL(String url, int offset)
offset in a certain file.
String URL of a fileint offset in the fileString URL that contains information about the position in this file,
String initial URL otherwisepublic Process exec(String command)
command in a separate process.String system command to be executedProcess object for managing the subprocesspublic Process exec(String command, String fileForOut)
command in a separate process, with the specifed output file.String system command to be executedString name of the output file of this processProcess object for managing the subprocesspublic String expandMacros(IdeContext context, String command)
command with the corresponding values.
IdeContext object that represents the Context
null is passed, only those macros that do not
String Source for macro substitutionnull if some macros cannot be executed, or
String command with macros replaced with the corresponding values,
public String[] getArguments()
String array with argumentspublic IdeCommandManager getCommandManager()
IdeCommandManagerpublic IdeConfigManager getConfigManager()
IdeConfigManagerpublic IdeDiagramManager getDiagramManager()
IdeDiagramManagerpublic IdeEditorManager getEditorManager()
IdeEditorManagerpublic String getHomeDirectory()
"C:\Cases\Together".String fully qualified path of Together's root directorypublic IdeMessageManager getMessageManager()
IdeMessageManagerpublic String getModuleHomeDirectory(Class moduleClass)
Class- Returns:
String home folder for this module- Since:
- Together 4.0
public IdeProgressIndicator getProgressIndicator()
IdeProgressIndicatorpublic IdeProjectManager getProjectManager()
IdeProjectManagerpublic String getTempFile()
String name of not existing temporary filepublic Locale getUILocale()
Locale object for the Together's User Interfacepublic IdeUndoManager getUndoManager()
public IdeWindowManager getWindowManager()
IdeWindowManagerpublic boolean isGUIEnabled()
true if it is allowed to display GUIpublic boolean isModuleActive(String moduleClassName)
true if activatable module is active.String name of the activatable module classtrue if module is activated, false otherwisepublic boolean isModuleServiceAvailable(String serviceName)
true if the service with the specified name
false otherwise.String name of the service to be checkedtrue if this service is available, false otherwise.public void navigateByURL(String url)
For example, for an URL to a diagram Together will open that diagram only if
the diagram pane is visible on the screen. For an URL to a file Together will open
this file in the text editor only if the editor pane is visible on the screen.
String internal URL (an URL to a diagram, file etc)public void openApplicationHelp(String topic, Component parent)
topic.String topic defined in the help config.Component dialog where the help was invoked.public void openHelp(String url)
public void openURL(String url)
"Open" means that IDE will handle specified URL in accordance with
its protocol's type. For example, for the http protocol IDE will show the data reffered to by the URL
in the default browser.
The URL's handler will be focused.
For example, for an http address Together will focus the browser, for internal URL
(to a file, diagram etc.) it will focus the corresponding pane.
String URLpublic IdeErrorInfo performCheck(IdeErrorCheck check)
run() method of the specified IdeErrorCheck object and returns
IdeErrorInfo containing the information about possible errors that occurred.IdeErrorCheck instance whose run method will be calledIdeErrorInfopublic void printStatus(String text)
String to be displayedpublic void saveAll()
public void setErrorInfo(IdeErrorInfo info)
IdeErrorInfo
IdeErrorInfo value.IdeErrorInfo instance that stores error detailspublic void showHelp(String targetID, boolean openInModalDialog, Component parent)
String ID defined in the help map fileboolean flag that defines how this help is diaplayed.
true shows help in the modal dialog.Component dialog where the help was invoked.public void showHelp(java.net.URL url, boolean openInModalDialog, Component parent)
java.net.URL specified URLboolean flag that defines how this help is diaplayed.
true shows help in the modal dialog.Component dialog where the help was invoked.public void synchronize()
| ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||