Package org.eclipse.debug.core
Interface ILaunch
-
- All Superinterfaces:
IAdaptable,ITerminate
- All Known Implementing Classes:
Launch
public interface ILaunch extends ITerminate, IAdaptable
A launch is the result of launching a debug session and/or one or more system processes.Clients are not required to implement this interface - they should use the implementation provided by the class
Launch. However, clients may implement this interface as required.- See Also:
Launch,IProcessFactory
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddDebugTarget(IDebugTarget target)Adds the given debug target to this launch.voidaddProcess(IProcess process)Adds the given process to this launch.StringgetAttribute(String key)Returns the value of a client defined attribute.Object[]getChildren()Returns the children of this launch - a collection of one or more debug targets and processes, possibly empty.IDebugTargetgetDebugTarget()Returns the primary (first) debug target associated with this launch, ornullif no debug target is associated with this launch.IDebugTarget[]getDebugTargets()Returns all the debug targets associated with this launch, or an empty collection if no debug targets are associated with this launch.ILaunchConfigurationgetLaunchConfiguration()Returns the configuration that was launched, ornullif no configuration was launched.StringgetLaunchMode()Returns the mode of this launch - one of the mode constants defined by the launch manager.IProcess[]getProcesses()Returns the processes that were launched, or an empty collection if no processes were launched.ISourceLocatorgetSourceLocator()Returns the source locator to use for locating source elements for the debug target associated with this launch, ornullif source lookup is not supported.booleanhasChildren()Returns whether this launch contains at least one process or debug target.voidremoveDebugTarget(IDebugTarget target)Removes the given debug target from this launch.voidremoveProcess(IProcess process)Removes the given process from this launch.voidsetAttribute(String key, String value)Sets the value of a client defined attribute.voidsetSourceLocator(ISourceLocator sourceLocator)Sets the source locator to use for locating source elements for the debug target associated with this launch, ornullif source lookup is not supported.-
Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
-
Methods inherited from interface org.eclipse.debug.core.model.ITerminate
canTerminate, isTerminated, terminate
-
-
-
-
Method Detail
-
getChildren
Object[] getChildren()
Returns the children of this launch - a collection of one or more debug targets and processes, possibly empty.- Returns:
- an array (element type:
IDebugTargetorIProcess), or an empty array
-
getDebugTarget
IDebugTarget getDebugTarget()
Returns the primary (first) debug target associated with this launch, ornullif no debug target is associated with this launch. All debug targets associated with this launch may be retrieved bygetDebugTargets().- Returns:
- the primary debug target associated with this launch, or
null
-
getProcesses
IProcess[] getProcesses()
Returns the processes that were launched, or an empty collection if no processes were launched.- Returns:
- array of processes
-
getDebugTargets
IDebugTarget[] getDebugTargets()
Returns all the debug targets associated with this launch, or an empty collection if no debug targets are associated with this launch. The primary debug target is the first in the collection (if any).- Returns:
- array of debug targets
- Since:
- 2.0
-
addDebugTarget
void addDebugTarget(IDebugTarget target)
Adds the given debug target to this launch. Has no effect if the given debug target is already associated with this launch. Registered listeners are notified that this launch has changed.- Parameters:
target- debug target to add to this launch- Since:
- 2.0
-
removeDebugTarget
void removeDebugTarget(IDebugTarget target)
Removes the given debug target from this launch. Has no effect if the given debug target is not already associated with this launch. Registered listeners are notified that this launch has changed.- Parameters:
target- debug target to remove from this launch- Since:
- 2.0
-
addProcess
void addProcess(IProcess process)
Adds the given process to this launch. Has no effect if the given process is already associated with this launch. Registered listeners are notified that this launch has changed.- Parameters:
process- the process to add to this launch- Since:
- 2.0
-
removeProcess
void removeProcess(IProcess process)
Removes the given process from this launch. Has no effect if the given process is not already associated with this launch. Registered listeners are notified that this launch has changed.- Parameters:
process- the process to remove from this launch- Since:
- 2.0
-
getSourceLocator
ISourceLocator getSourceLocator()
Returns the source locator to use for locating source elements for the debug target associated with this launch, ornullif source lookup is not supported.- Returns:
- the source locator
-
setSourceLocator
void setSourceLocator(ISourceLocator sourceLocator)
Sets the source locator to use for locating source elements for the debug target associated with this launch, ornullif source lookup is not supported.- Parameters:
sourceLocator- source locator ornull- Since:
- 2.0
-
getLaunchMode
String getLaunchMode()
Returns the mode of this launch - one of the mode constants defined by the launch manager.- Returns:
- the launch mode
- See Also:
ILaunchManager
-
getLaunchConfiguration
ILaunchConfiguration getLaunchConfiguration()
Returns the configuration that was launched, ornullif no configuration was launched.- Returns:
- the launched configuration or
null - Since:
- 2.0
-
setAttribute
void setAttribute(String key, String value)
Sets the value of a client defined attribute.- Parameters:
key- the attribute keyvalue- the attribute value- Since:
- 2.0
-
getAttribute
String getAttribute(String key)
Returns the value of a client defined attribute.- Parameters:
key- the attribute key- Returns:
- value the attribute value, or
nullif undefined - Since:
- 2.0
-
hasChildren
boolean hasChildren()
Returns whether this launch contains at least one process or debug target.- Returns:
- whether this launch contains at least one process or debug target
- Since:
- 2.0
-
-