Java Doc for IWorkbenchConfigurer.java in  » IDE-Eclipse » ui-workbench » org » eclipse » ui » application » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » IDE Eclipse » ui workbench » org.eclipse.ui.application 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.eclipse.ui.application.IWorkbenchConfigurer

All known Subclasses:   org.eclipse.ui.internal.WorkbenchConfigurer,
IWorkbenchConfigurer
public interface IWorkbenchConfigurer (Code)
Interface providing special access for configuring the workbench.

Note that these objects are only available to the main application (the plug-in that creates and owns the workbench).

This interface is not intended to be implemented by clients.


See Also:   WorkbenchAdvisor.initialize
since:
   3.0


Field Summary
final public static  intRESTORE_CODE_EXIT
     Restore status code indicating that the saved state could not be restored, and that the application must exit immediately without modifying any previously saved workbench state.
final public static  intRESTORE_CODE_RESET
     Restore status code indicating that the saved state could not be restored, but that startup should continue with a reset state.


Method Summary
public  voiddeclareImage(String symbolicName, ImageDescriptor descriptor, boolean shared)
     Declares a workbench image.
public  voidemergencyClose()
     Forces the workbench to close due to an emergency.
public  booleanemergencyClosing()
     Returns whether the workbench is being closed due to an emergency. When this method returns true, the workbench is in dire straights and cannot continue.
public  ObjectgetData(String key)
     Returns the data associated with the workbench at the given key.
public  booleangetExitOnLastWindowClose()
     Returns true if the workbench should exit when the last window is closed, false if the window should just be closed, leaving the workbench (and its event loop) running.

If true, the last window's state is saved before closing, so that it will be restored in the next session.

public  booleangetSaveAndRestore()
     Returns whether the workbench state should be saved on close and restored on subsequent open.
public  IWorkbenchWindowConfigurergetWindowConfigurer(IWorkbenchWindow window)
     Returns an object that can be used to configure the given window.
public  IWorkbenchgetWorkbench()
     Returns the underlying workbench.
public  WindowManagergetWorkbenchWindowManager()
     Returns the workbench window manager.
public  voidopenFirstTimeWindow()
     Opens the first time window, using the default perspective and default page input.
public  IStatusrestoreState()
     Restores the workbench state saved from the previous session, if any. This includes any open windows and their open perspectives, open views and editors, layout information, and any customizations to the open perspectives.
public  IWorkbenchWindowConfigurerrestoreWorkbenchWindow(IMemento memento)
     Restores a workbench window from the given memento.
public  voidsetData(String key, Object data)
     Sets the data associated with the workbench at the given key.
public  voidsetExitOnLastWindowClose(boolean enabled)
     Sets whether the workbench should exit when the last window is closed, or whether the window should just be closed, leaving the workbench (and its event loop) running.
public  voidsetSaveAndRestore(boolean enabled)
     Sets whether the workbench state should be saved on close and restored on subsequent open.

Field Detail
RESTORE_CODE_EXIT
final public static int RESTORE_CODE_EXIT(Code)
Restore status code indicating that the saved state could not be restored, and that the application must exit immediately without modifying any previously saved workbench state.



RESTORE_CODE_RESET
final public static int RESTORE_CODE_RESET(Code)
Restore status code indicating that the saved state could not be restored, but that startup should continue with a reset state.
See Also:   IWorkbenchConfigurer.restoreState





Method Detail
declareImage
public void declareImage(String symbolicName, ImageDescriptor descriptor, boolean shared)(Code)
Declares a workbench image.

The workbench remembers the given image descriptor under the given name, and makes the image available to plug-ins via IWorkbench.getSharedImages IWorkbench.getSharedImages() . For "shared" images, the workbench remembers the image descriptor and will manages the image object create from it; clients retrieve "shared" images via org.eclipse.ui.ISharedImages.getImage ISharedImages.getImage() . For the other, "non-shared" images, the workbench remembers only the image descriptor; clients retrieve the image descriptor via org.eclipse.ui.ISharedImages.getImageDescriptorISharedImages.getImageDescriptor() and are entirely responsible for managing the image objects they create from it. (This is made confusing by the historical fact that the API interface is called "ISharedImages".)


Parameters:
  symbolicName - the symbolic name of the image
Parameters:
  descriptor - the image descriptor
Parameters:
  shared - true if this is a shared image, andfalse if this is not a shared image
See Also:   org.eclipse.ui.ISharedImages.getImage
See Also:   org.eclipse.ui.ISharedImages.getImageDescriptor



emergencyClose
public void emergencyClose()(Code)
Forces the workbench to close due to an emergency. This method should only be called when the workbench is in dire straights and cannot continue, and cannot even risk a normal workbench close (think "out of memory" or "unable to create shell"). When this method is called, an abbreviated workbench shutdown sequence is performed (less critical steps may be skipped). The workbench advisor is still called; however, it must not attempt to communicate with the user. While an emergency close is in progress, emergencyClosing returns true. Workbench advisor methods should always check this flag before communicating with the user.
See Also:   IWorkbenchConfigurer.emergencyClosing



emergencyClosing
public boolean emergencyClosing()(Code)
Returns whether the workbench is being closed due to an emergency. When this method returns true, the workbench is in dire straights and cannot continue. Indeed, things are so bad that we cannot even risk a normal workbench close. Workbench advisor methods should always check this flag before attempting to communicate with the user. true if the workbench is in the process of beingclosed under emergency conditions, and false otherwise



getData
public Object getData(String key)(Code)
Returns the data associated with the workbench at the given key.
Parameters:
  key - the key the data, or null if there is no data at the givenkey



getExitOnLastWindowClose
public boolean getExitOnLastWindowClose()(Code)
Returns true if the workbench should exit when the last window is closed, false if the window should just be closed, leaving the workbench (and its event loop) running.

If true, the last window's state is saved before closing, so that it will be restored in the next session. This applies only if IWorkbenchConfigurer.getSaveAndRestore() returns true ).

If false, the window is simply closed, losing its state.

If the workbench is left running, it can be closed using IWorkbench.close , or a new window can be opened using IWorkbench.openWorkbenchWindow(StringIAdaptable) .

The initial value is true.

true if the workbench will exit when the lastwindow is closed, false if the window should justbe closed
since:
   3.1



getSaveAndRestore
public boolean getSaveAndRestore()(Code)
Returns whether the workbench state should be saved on close and restored on subsequent open.

The initial value is false.

true to save and restore workbench state, orfalse to forget current workbench state on close.



getWindowConfigurer
public IWorkbenchWindowConfigurer getWindowConfigurer(IWorkbenchWindow window)(Code)
Returns an object that can be used to configure the given window.
Parameters:
  window - a workbench window a workbench window configurer



getWorkbench
public IWorkbench getWorkbench()(Code)
Returns the underlying workbench. the workbench



getWorkbenchWindowManager
public WindowManager getWorkbenchWindowManager()(Code)
Returns the workbench window manager. the workbench window managerNote:IWorkbenchWindow is implemented using JFace's Window (and therefore uses WindowManager), but this is an implementation detail



openFirstTimeWindow
public void openFirstTimeWindow()(Code)
Opens the first time window, using the default perspective and default page input.

This is typically called from the advisor's openWindows() method.


See Also:   WorkbenchAdvisor.openWindows



restoreState
public IStatus restoreState()(Code)
Restores the workbench state saved from the previous session, if any. This includes any open windows and their open perspectives, open views and editors, layout information, and any customizations to the open perspectives.

This is typically called from the advisor's openWindows() method.

a status object indicating whether the restore was successful
See Also:   IWorkbenchConfigurer.RESTORE_CODE_RESET
See Also:   IWorkbenchConfigurer.RESTORE_CODE_EXIT
See Also:   WorkbenchAdvisor.openWindows



restoreWorkbenchWindow
public IWorkbenchWindowConfigurer restoreWorkbenchWindow(IMemento memento) throws WorkbenchException(Code)
Restores a workbench window from the given memento.
Parameters:
  memento - the memento from which to restore the window's state the configurer for the restored window
throws:
  WorkbenchException - if an error occurred during the restore
See Also:   IWorkbenchWindowConfigurer.saveState(IMemento)
since:
   3.1



setData
public void setData(String key, Object data)(Code)
Sets the data associated with the workbench at the given key.
Parameters:
  key - the key
Parameters:
  data - the data, or null to delete existing data



setExitOnLastWindowClose
public void setExitOnLastWindowClose(boolean enabled)(Code)
Sets whether the workbench should exit when the last window is closed, or whether the window should just be closed, leaving the workbench (and its event loop) running.

For more details, see IWorkbenchConfigurer.getExitOnLastWindowClose() .


Parameters:
  enabled - true if the workbench should exit when the lastwindow is closed, false if the window shouldjust be closed
since:
   3.1



setSaveAndRestore
public void setSaveAndRestore(boolean enabled)(Code)
Sets whether the workbench state should be saved on close and restored on subsequent open.
Parameters:
  enabled - true to save and restore workbench state, orfalse to forget current workbench state on close.



www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.