Class PrototypeTab
- All Implemented Interfaces:
IPrototypeAttributesLabelProvider
,ILaunchConfigurationTab
,ILaunchConfigurationTab2
Clients may call AbstractLaunchConfigurationTab.setHelpContextId(String)
on this tab prior to
control creation to alter the default context help associated with this tab.
Clients may instantiate this class only if the associated launch configuration type allows prototypes.
- Since:
- 3.13
- See Also:
- Restriction:
- This class is not intended to be subclassed by clients.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
activated
(ILaunchConfigurationWorkingCopy workingCopy) This method was added to theILaunchConfigurationTab
interface in the 3.0 release to allow tabs to distinguish between a tab being activated and a tab group be initialized for the first time, from a selected launch configuration.boolean
canSave()
Returns whether this tab is in a state that allows the launch configuration whose values this tab is showing to be saved.void
createControl
(Composite parent) Creates the top level control for this launch configuration tab under the given parent composite.void
deactivated
(ILaunchConfigurationWorkingCopy workingCopy) This method was added to theILaunchConfigurationTab
interface in the 3.0 release to allow tabs to distinguish between a tab being deactivated and saving its attributes to a launch configuration.void
dispose()
By default, do nothing.getId()
Returns this tab's unique identifier ornull
if none.getImage()
Returns the image for this tab, ornull
if nonegetName()
Returns the name of this tab.void
initializeFrom
(ILaunchConfiguration configuration) Initializes this tab's controls with values from the given launch configuration.boolean
isValid
(ILaunchConfiguration config) Returns whether this tab is in a valid state in the context of the specified launch configuration.void
performApply
(ILaunchConfigurationWorkingCopy configuration) Copies values from this tab into the given launch configuration.void
Perform the changes after apply.void
Initializes the given launch configuration with default values for this tab.Methods inherited from class org.eclipse.debug.ui.AbstractLaunchConfigurationTab
createCheckButton, createPushButton, createRadioButton, createSeparator, createUpdateJob, createVerticalSpacer, getAttributeLabel, getAttributesLabelsForPrototype, getControl, getErrorMessage, getHelpContextId, getLaunchConfigurationDialog, getLaunchManager, getMessage, getShell, getUpdateJobDelay, getWarningMessage, initializeAttributes, isDirty, launched, scheduleUpdateJob, setAttribute, setControl, setDirty, setErrorMessage, setHelpContextId, setLaunchConfigurationDialog, setMessage, setWarningMessage, updateLaunchConfigurationDialog
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.eclipse.debug.ui.ILaunchConfigurationTab
OkToLeaveTab
-
Constructor Details
-
PrototypeTab
public PrototypeTab()Constructs a new tab with default context help.
-
-
Method Details
-
createControl
Description copied from interface:ILaunchConfigurationTab
Creates the top level control for this launch configuration tab under the given parent composite. This method is called once on tab creation, aftersetLaunchConfigurationDialog
is called.Implementors are responsible for ensuring that the created control can be accessed via
getControl
- Parameters:
parent
- the parent composite
-
initializeFrom
Description copied from interface:ILaunchConfigurationTab
Initializes this tab's controls with values from the given launch configuration. This method is called when a configuration is selected to view or edit, after this tab's control has been created.- Parameters:
configuration
- launch configuration
-
dispose
public void dispose()Description copied from class:AbstractLaunchConfigurationTab
By default, do nothing.- Specified by:
dispose
in interfaceILaunchConfigurationTab
- Overrides:
dispose
in classAbstractLaunchConfigurationTab
- See Also:
-
activated
Description copied from class:AbstractLaunchConfigurationTab
This method was added to theILaunchConfigurationTab
interface in the 3.0 release to allow tabs to distinguish between a tab being activated and a tab group be initialized for the first time, from a selected launch configuration. To maintain backwards compatible behavior, the default implementation provided, calls this tab'sinitializeFrom
method. Tabs should override this method as required.The launch tab framework was originally designed to take care of inter tab communication by applying attributes from the active tab to the launch configuration being edited, when a tab is exited, and by initializing a tab when activated. The addition of the methods
activated
anddeactivated
allow tabs to determine the appropriate course of action.- Specified by:
activated
in interfaceILaunchConfigurationTab
- Overrides:
activated
in classAbstractLaunchConfigurationTab
- Parameters:
workingCopy
- the launch configuration being edited- See Also:
-
deactivated
Description copied from class:AbstractLaunchConfigurationTab
This method was added to theILaunchConfigurationTab
interface in the 3.0 release to allow tabs to distinguish between a tab being deactivated and saving its attributes to a launch configuration. To maintain backwards compatible behavior, the default implementation provided, calls this tab'sperformApply
method. Tabs should override this method as required.The launch tab framework was originally designed to take care of inter tab communication by applying attributes from the active tab to the launch configuration being edited, when a tab is exited, and by initializing a tab when activated. The addition of the methods
activated
anddeactivated
allow tabs to determine the appropriate course of action.- Specified by:
deactivated
in interfaceILaunchConfigurationTab
- Overrides:
deactivated
in classAbstractLaunchConfigurationTab
- Parameters:
workingCopy
- the launch configuration being edited- See Also:
-
isValid
Description copied from interface:ILaunchConfigurationTab
Returns whether this tab is in a valid state in the context of the specified launch configuration.This information is typically used by the launch configuration dialog to decide when it is okay to launch.
- Specified by:
isValid
in interfaceILaunchConfigurationTab
- Overrides:
isValid
in classAbstractLaunchConfigurationTab
- Parameters:
config
- launch configuration which provides context for validating this tab. This value must not benull
.- Returns:
- whether this tab is in a valid state
- See Also:
-
setDefaults
Description copied from interface:ILaunchConfigurationTab
Initializes the given launch configuration with default values for this tab. This method is called when a new launch configuration is created such that the configuration can be initialized with meaningful values. This method may be called before this tab's control is created.- Parameters:
config
- launch configuration
-
performApply
Description copied from interface:ILaunchConfigurationTab
Copies values from this tab into the given launch configuration.- Parameters:
configuration
- launch configuration
-
postApply
public void postApply()Description copied from interface:ILaunchConfigurationTab
Perform the changes after apply. -
getName
Description copied from interface:ILaunchConfigurationTab
Returns the name of this tab.- Returns:
- the name of this tab
-
getImage
Description copied from interface:ILaunchConfigurationTab
Returns the image for this tab, ornull
if none- Specified by:
getImage
in interfaceILaunchConfigurationTab
- Overrides:
getImage
in classAbstractLaunchConfigurationTab
- Returns:
- the image for this tab, or
null
if none - See Also:
-
getId
Description copied from class:AbstractLaunchConfigurationTab
Returns this tab's unique identifier ornull
if none. By default,null
is returned. Subclasses should override as necessary.Tab identifiers allow contributed tabs to be ordered relative to one another.
- Overrides:
getId
in classAbstractLaunchConfigurationTab
- Returns:
- tab id or
null
- See Also:
-
canSave
public boolean canSave()Description copied from interface:ILaunchConfigurationTab
Returns whether this tab is in a state that allows the launch configuration whose values this tab is showing to be saved. This differs fromisValid()
in thatcanSave()
determines if this tab prevents the current launch configuration from being saved, whereasisValid()
determines if this tab prevents the current launch configuration from being launched.This information is typically used by the launch configuration dialog to decide when it is okay to save a launch configuration.
- Specified by:
canSave
in interfaceILaunchConfigurationTab
- Overrides:
canSave
in classAbstractLaunchConfigurationTab
- Returns:
- whether this tab is in a state that allows the current launch configuration to be saved
- See Also:
-