Package org.eclipse.launchbar.core
Class DefaultLaunchConfigProvider
java.lang.Object
org.eclipse.launchbar.core.DefaultLaunchConfigProvider
- All Implemented Interfaces:
ILaunchConfigurationProvider
The launch config provider for the default descriptor which is the launch
config itself.
Override this class and register an extension if you want to support targets
other than the local connection.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.eclipse.debug.core.ILaunchConfigurationgetLaunchConfiguration(ILaunchDescriptor descriptor, ILaunchTarget target) Create a launch configuration for the descriptor to launch on the target.org.eclipse.debug.core.ILaunchConfigurationTypegetLaunchConfigurationType(ILaunchDescriptor descriptor, ILaunchTarget target) Return the launch configuation type for the descriptor and target.booleanlaunchConfigurationAdded(org.eclipse.debug.core.ILaunchConfiguration configuration) A launch configuration has been added.booleanlaunchConfigurationChanged(org.eclipse.debug.core.ILaunchConfiguration configuration) A launch configuration has been changed.booleanlaunchConfigurationRemoved(org.eclipse.debug.core.ILaunchConfiguration configuration) A launch configuration has been removed.booleanlaunchDescriptorMatches(ILaunchDescriptor descriptor, org.eclipse.debug.core.ILaunchConfiguration configuration, ILaunchTarget target) Return true if given descriptor is associated with given launch configuration.voidlaunchDescriptorRemoved(ILaunchDescriptor descriptor) A launch descriptor has been removed.voidlaunchTargetRemoved(ILaunchTarget target) A launch target has been removed.booleansupports(ILaunchDescriptor descriptor, ILaunchTarget target) Does this config provider provide launch configurations for the combination of descriptor and target.
-
Constructor Details
-
DefaultLaunchConfigProvider
public DefaultLaunchConfigProvider()
-
-
Method Details
-
supports
public boolean supports(ILaunchDescriptor descriptor, ILaunchTarget target) throws org.eclipse.core.runtime.CoreException Description copied from interface:ILaunchConfigurationProviderDoes this config provider provide launch configurations for the combination of descriptor and target. Note: this is called when filtering targets for a descriptor. Processing should be minimal.- Specified by:
supportsin interfaceILaunchConfigurationProvider- Parameters:
descriptor-target-- Returns:
- true if target is supported, false otherwise.
- Throws:
org.eclipse.core.runtime.CoreException
-
getLaunchConfigurationType
public org.eclipse.debug.core.ILaunchConfigurationType getLaunchConfigurationType(ILaunchDescriptor descriptor, ILaunchTarget target) throws org.eclipse.core.runtime.CoreException Description copied from interface:ILaunchConfigurationProviderReturn the launch configuation type for the descriptor and target.- Specified by:
getLaunchConfigurationTypein interfaceILaunchConfigurationProvider- Parameters:
descriptor-target- launch configuration type or null if not supported- Returns:
- Throws:
org.eclipse.core.runtime.CoreException
-
getLaunchConfiguration
public org.eclipse.debug.core.ILaunchConfiguration getLaunchConfiguration(ILaunchDescriptor descriptor, ILaunchTarget target) throws org.eclipse.core.runtime.CoreException Description copied from interface:ILaunchConfigurationProviderCreate a launch configuration for the descriptor to launch on the target.- Specified by:
getLaunchConfigurationin interfaceILaunchConfigurationProvider- Parameters:
descriptor- the descriptor to create the config fortarget- the target to launch the config on- Returns:
- launch configuration
- Throws:
org.eclipse.core.runtime.CoreException
-
launchConfigurationAdded
public boolean launchConfigurationAdded(org.eclipse.debug.core.ILaunchConfiguration configuration) throws org.eclipse.core.runtime.CoreException Description copied from interface:ILaunchConfigurationProviderA launch configuration has been added. Provider can inspect it and associate with internal map. Provider should make sure it owns this launch configuration or it can modify it to take over.- Specified by:
launchConfigurationAddedin interfaceILaunchConfigurationProvider- Returns:
- true of provider owns this launch configuration
- Throws:
org.eclipse.core.runtime.CoreException
-
launchConfigurationChanged
public boolean launchConfigurationChanged(org.eclipse.debug.core.ILaunchConfiguration configuration) throws org.eclipse.core.runtime.CoreException Description copied from interface:ILaunchConfigurationProviderA launch configuration has been changed. Provider can inspect it to re-evaluate its internal map. Provider should make sure it owns this launch configuration or it can modify it to take over.- Specified by:
launchConfigurationChangedin interfaceILaunchConfigurationProvider- Returns:
- true of provider owns this launch configuration
- Throws:
org.eclipse.core.runtime.CoreException
-
launchConfigurationRemoved
public boolean launchConfigurationRemoved(org.eclipse.debug.core.ILaunchConfiguration configuration) throws org.eclipse.core.runtime.CoreException Description copied from interface:ILaunchConfigurationProviderA launch configuration has been removed. This notification can be used to purge internal cache for example. This method is called after launch configuration has been removed from file system, so accessing its attributes won't work. If provider cannot determine if it owns it it should return false.- Specified by:
launchConfigurationRemovedin interfaceILaunchConfigurationProvider- Parameters:
configuration-- Returns:
- true if provider owns this launch configuration
- Throws:
org.eclipse.core.runtime.CoreException
-
launchDescriptorRemoved
public void launchDescriptorRemoved(ILaunchDescriptor descriptor) throws org.eclipse.core.runtime.CoreException Description copied from interface:ILaunchConfigurationProviderA launch descriptor has been removed. Remove any launch configurations that were created for it.- Specified by:
launchDescriptorRemovedin interfaceILaunchConfigurationProvider- Parameters:
descriptor-- Throws:
org.eclipse.core.runtime.CoreException
-
launchTargetRemoved
Description copied from interface:ILaunchConfigurationProviderA launch target has been removed. Remove any launch configurations that were created for it.- Specified by:
launchTargetRemovedin interfaceILaunchConfigurationProvider- Parameters:
target-- Throws:
org.eclipse.core.runtime.CoreException
-
launchDescriptorMatches
public boolean launchDescriptorMatches(ILaunchDescriptor descriptor, org.eclipse.debug.core.ILaunchConfiguration configuration, ILaunchTarget target) throws org.eclipse.core.runtime.CoreException Description copied from interface:ILaunchConfigurationProviderReturn true if given descriptor is associated with given launch configuration. I.e. if getLaunchConfiguration(descriptor, target) returns a launch configuration, calling launchDescriptorMatches(descriptor, configuration, target) should return true. This method is used to activate descriptor when launch happens, return false all the time would mean launch would track launches of this specific descriptor (if they occur outside of launchbar).- Specified by:
launchDescriptorMatchesin interfaceILaunchConfigurationProvider- Parameters:
configuration- launch configuration in questiontarget- - target to match, it can be null if launch bar cannot determine target, in this case it should act as wildcard- Returns:
- launch configuration
- Throws:
org.eclipse.core.runtime.CoreException
-