Package org.eclipse.launchbar.core

# Class AbstractLaunchConfigProvider

java.lang.Object
org.eclipse.launchbar.core.AbstractLaunchConfigProvider

All Implemented Interfaces:
  `ILaunchConfigurationProvider`

Direct Known Subclasses:
  `PerTargetLaunchConfigProvider`, `ProjectLaunchConfigProvider`

public abstract class AbstractLaunchConfigProvider extends Object implements ILaunchConfigurationProvider
Common launch config provider. Manages creating launch configurations and ensuring duplicates are managed properly.

## Constructor Summary

Constructors
Constructor
Description
`AbstractLaunchConfigProvider()`

## Method Summary

Modifier and Type
Method
Description
`protected org.eclipse.debug.core.ILaunchConfiguration`
`createLaunchConfiguration(ILaunchDescriptor descriptor, ILaunchTarget target)`
`boolean`
`launchDescriptorMatches(ILaunchDescriptor descriptor, org.eclipse.debug.core.ILaunchConfiguration configuration, ILaunchTarget target)`
Return true if given descriptor is associated with given launch configuration.
`protected boolean`
`ownsLaunchConfiguration(org.eclipse.debug.core.ILaunchConfiguration configuration)`
`protected void`
`populateLaunchConfiguration(ILaunchDescriptor descriptor, ILaunchTarget target, org.eclipse.debug.core.ILaunchConfigurationWorkingCopy workingCopy)`
Populate the newly created launch configuration with the target's attributes.
`protected void`
`updateLaunchConfiguration(org.eclipse.debug.core.ILaunchConfiguration config, ILaunchTarget target)`
Update an existing launch configuration to match the target's attributes.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface org.eclipse.launchbar.core.ILaunchConfigurationProvider

`getLaunchConfiguration, getLaunchConfigurationType, launchConfigurationAdded, launchConfigurationChanged, launchConfigurationRemoved, launchDescriptorRemoved, launchTargetRemoved, supports`

## Constructor Details

### AbstractLaunchConfigProvider

public AbstractLaunchConfigProvider()

## Method Details

### createLaunchConfiguration

protected org.eclipse.debug.core.ILaunchConfiguration createLaunchConfiguration(ILaunchDescriptor descriptor, ILaunchTarget target) throws org.eclipse.core.runtime.CoreException

Throws:
  `org.eclipse.core.runtime.CoreException`

### updateLaunchConfiguration

protected void updateLaunchConfiguration(org.eclipse.debug.core.ILaunchConfiguration config, ILaunchTarget target) throws org.eclipse.core.runtime.CoreException
Update an existing launch configuration to match the target's attributes.

Parameters:
  `config` - the launch configuration to update
  `target` - the launch target to get attributes from
Throws:
  `org.eclipse.core.runtime.CoreException` - if unable to update the launch configuration
Since:
  3.1

### populateLaunchConfiguration

protected void populateLaunchConfiguration(ILaunchDescriptor descriptor, ILaunchTarget target, org.eclipse.debug.core.ILaunchConfigurationWorkingCopy workingCopy) throws org.eclipse.core.runtime.CoreException
Populate the newly created launch configuration with the target's attributes.

Parameters:
  `descriptor` - the launch descriptor
  `target` - the launch target
Throws:
  `org.eclipse.core.runtime.CoreException` - if unable to get the launch configuration type

### launchDescriptorMatches

public boolean launchDescriptorMatches(ILaunchDescriptor descriptor, org.eclipse.debug.core.ILaunchConfiguration configuration, ILaunchTarget target) throws org.eclipse.core.runtime.CoreException
Description copied from interface: `ILaunchConfigurationProvider`
Return 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:
  `launchDescriptorMatches` in interface `ILaunchConfigurationProvider`
Parameters:
  `configuration` - launch configuration in question
  `target` - - 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`

### ownsLaunchConfiguration

protected boolean ownsLaunchConfiguration(org.eclipse.debug.core.ILaunchConfiguration configuration) throws org.eclipse.core.runtime.CoreException

Throws:
  `org.eclipse.core.runtime.CoreException`