|
Eclipse Platform Release 3.6 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.debug.ui.AbstractLaunchConfigurationTab
org.eclipse.debug.ui.WorkingDirectoryBlock
public abstract class WorkingDirectoryBlock
A control for setting the working directory associated with a launch configuration.
Constructor Summary | |
---|---|
protected |
WorkingDirectoryBlock(String workingDirectoryAttribteName)
Creates a new WorkingDirectoryBlock for setting a working directory. |
protected |
WorkingDirectoryBlock(String workingDirectoryAttribteName,
String helpContextId)
Creates a new WorkingDirectoryBlock for setting a working directory. |
Method Summary | |
---|---|
void |
createControl(Composite parent)
Creates the top level control for this launch configuration tab under the given parent composite. |
protected IContainer |
getContainer()
Returns the selected workspace container,or null |
protected ILaunchConfiguration |
getLaunchConfiguration()
Returns the launch configuration that this working directory block is using. |
String |
getName()
Returns the name of this tab. |
protected abstract IProject |
getProject(ILaunchConfiguration configuration)
Returns the project associated with the specified launch configuration or null if none. |
protected String |
getWorkingDirectoryText()
Retrieves the path from the text box that has been selected. |
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. |
protected void |
log(CoreException e)
Logs exceptions that have been caught by this working directory block. |
void |
performApply(ILaunchConfigurationWorkingCopy configuration)
Copies values from this tab into the given launch configuration. |
void |
setDefaults(ILaunchConfigurationWorkingCopy config)
Sets the default working directory to be used by the launch configuration. |
protected void |
setDefaultWorkingDir()
Sets the default working directory. |
protected void |
setDefaultWorkingDirectoryText(String dir)
Sets the text of the default working directory. |
void |
setEnabled(boolean enabled)
Allows this entire block to be enabled/disabled |
protected void |
setLaunchConfiguration(ILaunchConfiguration config)
Sets the launch configuration to be used by this working directory block. |
protected void |
setOtherWorkingDirectoryText(String dir)
Sets the directory of the other working directory to be used. |
Methods inherited from class org.eclipse.debug.ui.AbstractLaunchConfigurationTab |
---|
activated, canSave, createCheckButton, createPushButton, createRadioButton, createSeparator, createUpdateJob, createVerticalSpacer, deactivated, dispose, getControl, getErrorMessage, getId, getImage, getLaunchConfigurationDialog, getLaunchManager, getMessage, getShell, getUpdateJobDelay, isDirty, launched, scheduleUpdateJob, setAttribute, setControl, setDirty, setErrorMessage, setLaunchConfigurationDialog, setMessage, updateLaunchConfigurationDialog |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected WorkingDirectoryBlock(String workingDirectoryAttribteName)
workingDirectoryAttribteName
- the name of the launch configuration attribute to set the working directory's location, cannot be nullprotected WorkingDirectoryBlock(String workingDirectoryAttribteName, String helpContextId)
workingDirectoryAttribteName
- the name of the launch configuration attribute to set the working directory's location, cannot be nullhelpContextId
- the help context id to use to hook onto the help systemMethod Detail |
---|
public final void createControl(Composite parent)
ILaunchConfigurationTab
setLaunchConfigurationDialog
is called.
Implementors are responsible for ensuring that
the created control can be accessed via getControl
parent
- the parent compositeprotected IContainer getContainer()
null
protected void setDefaultWorkingDir()
protected abstract IProject getProject(ILaunchConfiguration configuration) throws CoreException
null
if none.
configuration
- the launch configuration that has been set to this working directory block
CoreException
- if an error occurred while retrieving the project from the launch configurationpublic boolean isValid(ILaunchConfiguration config)
ILaunchConfigurationTab
This information is typically used by the launch configuration dialog to decide when it is okay to launch.
isValid
in interface ILaunchConfigurationTab
isValid
in class AbstractLaunchConfigurationTab
config
- launch configuration which provides context for validating this tab.
This value must not be null
.
ILaunchConfigurationTab.isValid(ILaunchConfiguration)
public void setDefaults(ILaunchConfigurationWorkingCopy config)
config
- launch configurationILaunchConfigurationTab.setDefaults(org.eclipse.debug.core.ILaunchConfigurationWorkingCopy)
public void initializeFrom(ILaunchConfiguration configuration)
ILaunchConfigurationTab
configuration
- launch configurationpublic void performApply(ILaunchConfigurationWorkingCopy configuration)
ILaunchConfigurationTab
configuration
- launch configurationpublic String getName()
ILaunchConfigurationTab
protected void log(CoreException e)
e
- the exception to logprotected final String getWorkingDirectoryText()
protected final void setDefaultWorkingDirectoryText(String dir)
dir
- the directory to set the widget toprotected final void setOtherWorkingDirectoryText(String dir)
dir
- the directory to set the widget toprotected void setLaunchConfiguration(ILaunchConfiguration config)
protected ILaunchConfiguration getLaunchConfiguration()
public final void setEnabled(boolean enabled)
enabled
- whether to enable it or not
|
Eclipse Platform Release 3.6 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Guidelines for using Eclipse APIs.
Copyright (c) Eclipse contributors and others 2000, 2010. All rights reserved.