Shows the specified perspective to the user. The caller should use this method when the perspective to be shown is not dependent on the page's input. That is, the perspective can open in any page depending on user preferences.
The perspective may be shown in the specified window, in another existing window, or in a new window depending on user preferences. The exact policy is controlled by the workbench to ensure consistency to the user. The policy is subject to change. The current policy is as follows:
- If the specified window has the requested perspective open, then the window is given focus and the perspective is shown. The page's input is ignored.
- If another window that has the workspace root as input and the requested perspective open and active, then the window is given focus.
- Otherwise the requested perspective is opened and shown in the specified window or in a new window depending on the current user preference for opening perspectives, and that window is given focus.
The workbench also defines a number of menu items to activate or open each registered perspective. A complete list of these perspectives is available from the perspective registry found on IWorkbench
.
@param perspectiveId the perspective ID to show
@param window the workbench window of the action calling this method.
@return the workbench page that the perspective was shown
@exception WorkbenchException if the perspective could not be shown
@since 2.0