Skip to main content

IWorkspace Interface

Namespace: NextDesign.Desktop

Description

Provides access to application workspace information.

Belonging Area

NameDescription
Workspace ProjectA set of APIs to access the application workspace and projects open in the application.

Property

NameDescription
CurrentEditorEditor information displayed in the currently selected editor view
If no editor is displayed, returns null.
CurrentModelThe model element selected in the current project.
If no model is selected, returns null.
CurrentProductThe currently applied product in the current project.
CurrentProjectCurrent project
Returns information about the project currently open in the application's workspace.
If no project is open in the application, returns null.
ErrorsList of errors
This object allows you to access information about currently registered errors.
InfoDisplayStyleSetStyle set definition
This object allows you to manage the styles that can be specified when displaying errors and search results.
MainEditorEditor information displayed in the current main editor view
If no editor is displayed, returns null.
OutputOutput
This object allows you to access the application's output.
ProjectAutoReloadReload project

Gets or sets whether to automatically reload the project when changes are made outside of Next Design. If the project is automatically reloaded, a confirmation dialog is displayed.
Specify true to reload the project, or false not to reload it.
ScmConfiguration management access object
SearchSearch
This object allows you to access the list of search results.
StateWorkspace state
SubEditorEditor information displayed in the current subeditor view
If no editor is displayed, returns null.

Method

NameDescription
CanRedoChecks whether an edit operation that was undone can be redone.
CanUndoChecks whether an edit operation can be undone.
CleanUpProjectCleans up the specified project.
If no project is specified, cleans up the current project currently open in the application.

The project cleanup process is performed only on editable units among the managed units of the specified project.
Note that if the target project has not been saved, this method call will fail.
CloseDiffEnds the difference comparison.
CloseProjectCloses the specified project.
If no project is specified, the current project currently open in the application will be closed.

This call discards changes and closes the project without warning even if the target project has not been saved.
CreateSearch[Obsolete] Creates a search object.
This object can be used to start and end searches and register search results.
GenerateDocumentGenerates a document.
The selected element in the model navigator is used as the base model for output.
GetModelUnitByLoadModeGets the model unit with the specified load mode.
LoadModelUnits(IProject,IEnumerable<IModelUnit>)Adds the specified model unit to the specified project.
If the specified unit has already been loaded or is not managed by the specified project, it will be ignored.

If the target project is the current project, the busy indicator will be displayed and the method will be executed. However, it cannot be canceled.
Note that if the target project has not been saved, this method will fail. If the target project is the current project, a message dialog will be displayed on the ND, just as when executed from the project navigator, and the additional loading will be aborted. If the project is not the current one, an exception occurs.
LoadModelUnits(IProject,IEnumerable<string>)Adds and loads the specified model units in the specified project.
If the specified unit has already been loaded or is not managed by the specified project, it will be ignored.

If the target project is the current project, the busy indicator will be displayed and the method will be executed. However, cancellation is not possible.
Note that if the target project has not been saved, calling this method will fail. If the target project is the current project, a message dialog will be displayed on ND and the additional loading will be aborted, just as if it was executed from the project navigator. If the project is not the current one, an exception will occur.
NewProjectCreates a new project.
OpenDiffDisplays a difference comparison from the specified difference comparison information.
OpenProject(string,bool,bool)Opens the specified project.

OpenProject(string,OpenProjectOptions)Opens the project with the specified options.
RedoRedoes an edit operation that was undone.
ReloadProjectReloads the specified project.
If no project is specified, reloads the current project currently open in the application.
SaveAllResaves the file based on its latest state.
If no project is specified, the current project is saved.

If no file has been created for the specified project, an exception is thrown.
Units that are not loaded or are read-only will not be saved.
SaveProjectSaves the specified project.
If no project is specified, the current project currently open in the application is saved.
Returns True if the save is successful.
If you use this method when you cannot obtain file access rights or there is not enough free space, the project is not saved and this method returns False.

The project is saved to the path that can be obtained by IProject.Path.
Therefore, this method cannot be executed for a project that has not been saved since it was created.
When saving a new project, use SaveProjectAs().
SaveProjectAsSaves the specified project in the specified path.
If no project is specified, saves the current project currently open in the application.
Returns True if the save was successful.

This call will silently overwrite the file if one already exists at the specified path.
If the save is successful, the target project's Path will be replaced with the new path.
SetLoadModeSets the load mode for the model unit.
Ignored if the specified unit is not managed by the specified project.
UndoUndoes an edit operation.