|
Eclipse Platform 2.0 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.eclipse.debug.ui.DebugUITools
This class provides utilities for clients of the debug UI.
Images retrieved from this facility should not be disposed. The images will be disposed when this plugin is shutdown.
This class is not intended to be subclassed or instantiated.
Constructor Summary | |
DebugUITools()
|
Method Summary | |
static IProcess |
getCurrentProcess()
Returns the process associated with the current debug context. |
static IAdaptable |
getDebugContext()
Returns the currently selected element in the debug view of the current workbench page, or null if there is no current
debug context, or if not called from the UI
thread. |
static ImageDescriptor |
getDefaultImageDescriptor(Object element)
Returns the default image descriptor for the given element or null if none is defined. |
static Image |
getImage(String key)
Returns the shared image managed under the given key, or null
if none. |
static ImageDescriptor |
getImageDescriptor(String key)
Returns the shared image descriptor managed under the given key, or null if none. |
static IPreferenceStore |
getPreferenceStore()
Returns the preference store for the debug UI plugin. |
static IDebugModelPresentation |
newDebugModelPresentation()
Returns a new debug model presentation that delegates to appropriate debug models. |
static IDebugModelPresentation |
newDebugModelPresentation(String identifier)
Returns a new debug model presentation for specified debug model, or null if a presentation does
not exist. |
static int |
openLaunchConfigurationDialog(Shell shell,
IStructuredSelection selection,
String mode)
Open the launch configuration dialog with the specified initial selection. |
static boolean |
saveAndBuildBeforeLaunch()
Saves all dirty editors and builds the workspace according to current preference settings, and returns whether a launch should proceed. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public DebugUITools()
Method Detail |
public static Image getImage(String key)
null
if none.
Note that clients MUST NOT dispose the image returned by this method.
See IDebugUIConstants
for available images.
key
- the image key
null
if noneIDebugUIConstants
public static ImageDescriptor getImageDescriptor(String key)
null
if none.
See IDebugUIConstants
for available image descriptors.
key
- the image descriptor key
null
if noneIDebugUIConstants
public static ImageDescriptor getDefaultImageDescriptor(Object element)
null
if none is defined.
public static IPreferenceStore getPreferenceStore()
public static IDebugModelPresentation newDebugModelPresentation()
It is the client's responsibility dispose the presentation.
IBaseLabelProvider.dispose()
public static IDebugModelPresentation newDebugModelPresentation(String identifier)
null
if a presentation does
not exist.
It is the client's responsibility dispose the presentation.
identifier
- debug model identifier
null
IBaseLabelProvider.dispose()
public static IAdaptable getDebugContext()
null
if there is no current
debug context, or if not called from the UI
thread.
null
public static IProcess getCurrentProcess()
null
is returned.
null
public static int openLaunchConfigurationDialog(Shell shell, IStructuredSelection selection, String mode)
null
, or contain any mix of
ILaunchConfiguration
or ILaunchConfigurationType
elements.
shell
- the parent shell for the launch configuration dialogselection
- the initial selection for the dialogmode
- the mode (run or debug) in which to open the launch configuration dialog.
This should be one of the constants defined in ILaunchManager
.
public static boolean saveAndBuildBeforeLaunch()
The following preferences effect whether dirty editors are saved, and/or if the user is prompted to save dirty edtiors:
|
Eclipse Platform 2.0 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |