Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "FAQ How do I make the workbench shutdown?"

 
m
 
Line 1: Line 1:
You can force the workbench to exit by calling the <tt>close</tt>
+
You can force the workbench to exit by calling the <tt>close</tt> method on <tt>IWorkbench</tt>.  This is the same behavior as would occur if the end user had selected '''File &gt; Exit'''. If you want the workbench to close and immediately restart&#151;for example, if a new plug-in has been installed
method on <tt>IWorkbench</tt>.  This is the same behavior as would occur if the
+
and you have a plug-in that does not support dynamic plug-ins&#151;you can instead call the <tt>restart</tt> method.
end user had selected '''File &gt; Exit'''.
+
If you want the workbench to close
+
and immediately restart&#151;for example, if a new plug-in has been installed
+
and you have a plug-in that does not support dynamic plug-ins&#151;you
+
can instead call the <tt>restart</tt> method.
+
  
 +
Note that although API exists for exiting and restarting the workbench, this measure is fairly drastic and should not be employed lightly.  As support for dynamically installed plug-ins increases, it will become increasingly unacceptable to restart the workbench to install new plug-ins.  At the very least, before calling either of these methods,  you should prompt the user as to whether he or she want to exit.
  
Note that although API exists for exiting and restarting the workbench,
+
{{Template:FAQ_Tagline}}
this measure is fairly drastic and should not be employed lightly.  As
+
support for dynamically installed plug-ins increases, it will become
+
increasingly unacceptable to restart the workbench to
+
install new plug-ins.  At the very least, before calling either of these methods,
+
you should prompt the user as to whether he or she want to exit.
+
 
+
<hr><font size=-2>This FAQ was originally published in [http://www.eclipsefaq.org Official Eclipse 3.0 FAQs]. Copyright 2004, Pearson Education, Inc. All rights reserved. This text is made available here under the terms of the [http://www.eclipse.org/legal/epl-v10.html Eclipse Public License v1.0].</font>
+

Latest revision as of 00:37, 9 June 2006

You can force the workbench to exit by calling the close method on IWorkbench. This is the same behavior as would occur if the end user had selected File > Exit. If you want the workbench to close and immediately restart&#151;for example, if a new plug-in has been installed and you have a plug-in that does not support dynamic plug-ins&#151;you can instead call the restart method.

Note that although API exists for exiting and restarting the workbench, this measure is fairly drastic and should not be employed lightly. As support for dynamically installed plug-ins increases, it will become increasingly unacceptable to restart the workbench to install new plug-ins. At the very least, before calling either of these methods, you should prompt the user as to whether he or she want to exit.


This FAQ was originally published in Official Eclipse 3.0 FAQs. Copyright 2004, Pearson Education, Inc. All rights reserved. This text is made available here under the terms of the Eclipse Public License v1.0.

Back to the top