Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.eclipse.jdt.debug.ui.launchConfigurations
Class JavaClasspathTab  view JavaClasspathTab download JavaClasspathTab.java

java.lang.Object
  extended byorg.eclipse.debug.ui.AbstractLaunchConfigurationTab
      extended byorg.eclipse.jdt.internal.debug.ui.launcher.JavaLaunchConfigurationTab
          extended byorg.eclipse.jdt.debug.ui.launchConfigurations.JavaClasspathTab
All Implemented Interfaces:
org.eclipse.jdt.internal.debug.ui.launcher.IEntriesChangedListener, org.eclipse.debug.ui.ILaunchConfigurationTab

public class JavaClasspathTab
extends org.eclipse.jdt.internal.debug.ui.launcher.JavaLaunchConfigurationTab

A launch configuration tab that displays and edits the user and bootstrap classes comprising the classpath launch configuration attribute.

This class may be instantiated. This class is not intended to be subclassed.

Since:
2.0

Field Summary
protected static java.lang.String DIALOG_SETTINGS_PREFIX
           
protected  org.eclipse.jdt.internal.debug.ui.classpath.RuntimeClasspathViewer fClasspathViewer
           
protected  org.eclipse.debug.core.ILaunchConfiguration fLaunchConfiguration
          The last launch config this tab was initialized from
private  org.eclipse.jdt.internal.debug.ui.classpath.ClasspathModel fModel
           
 
Fields inherited from class org.eclipse.debug.ui.AbstractLaunchConfigurationTab
 
Constructor Summary
JavaClasspathTab()
           
 
Method Summary
 void activated(org.eclipse.debug.core.ILaunchConfigurationWorkingCopy workingCopy)
          This method was added to the ILaunchConfigurationTab 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.
protected  org.eclipse.swt.widgets.Button createButton(org.eclipse.swt.widgets.Composite pathButtonComp, org.eclipse.jdt.internal.debug.ui.actions.RuntimeClasspathAction action)
          Creates a button for the given action.
private  void createClasspathModel(org.eclipse.debug.core.ILaunchConfiguration configuration)
           
 void createControl(org.eclipse.swt.widgets.Composite parent)
          Creates the top level control for this launch configuration tab under the given parent composite.
protected  void createPathButtons(org.eclipse.swt.widgets.Composite pathButtonComp)
          Creates the buttons to manipulate the classpath.
 void dispose()
          By default, do nothing.
static org.eclipse.swt.graphics.Image getClasspathImage()
           
private  org.eclipse.jdt.launching.IRuntimeClasspathEntry[] getCurrentClasspath()
          Returns the classpath entries currently specified by this tab.
 org.eclipse.swt.graphics.Image getImage()
          Returns the image for this tab, or null if none
 org.eclipse.debug.core.ILaunchConfiguration getLaunchConfiguration()
          Returns the current launch configuration
protected  org.eclipse.jdt.internal.debug.ui.classpath.ClasspathModel getModel()
           
 java.lang.String getName()
          Returns the name of this tab.
 void initializeFrom(org.eclipse.debug.core.ILaunchConfiguration configuration)
          Initializes this tab's controls with values from the given launch configuration.
private  boolean isDefaultClasspath(org.eclipse.jdt.launching.IRuntimeClasspathEntry[] classpath, org.eclipse.debug.core.ILaunchConfiguration configuration)
          Returns whether the specified classpath is equivalent to the default classpath for this configuration.
 boolean isShowBootpath()
          Returns whether the bootpath should be displayed.
 boolean isValid(org.eclipse.debug.core.ILaunchConfiguration launchConfig)
          Returns whether this tab is in a valid state in the context of the specified launch configuration.
 void performApply(org.eclipse.debug.core.ILaunchConfigurationWorkingCopy configuration)
          Copies values from this tab into the given launch configuration.
private  void refresh(org.eclipse.debug.core.ILaunchConfiguration configuration)
          Refreshes the classpath entries based on the current state of the given launch configuration.
 void setDefaults(org.eclipse.debug.core.ILaunchConfigurationWorkingCopy configuration)
          Initializes the given launch configuration with default values for this tab.
private  void setLaunchConfiguration(org.eclipse.debug.core.ILaunchConfiguration config)
          Sets the launch configuration for this classpath tab
 
Methods inherited from class org.eclipse.jdt.internal.debug.ui.launcher.JavaLaunchConfigurationTab
entriesChanged, getContext, initializeJavaProject
 
Methods inherited from class org.eclipse.debug.ui.AbstractLaunchConfigurationTab
canSave, createCheckButton, createPushButton, createRadioButton, createSeparator, createVerticalSpacer, deactivated, getControl, getErrorMessage, getLaunchConfigurationDialog, getLaunchManager, getMessage, getShell, isDirty, launched, 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
 

Field Detail

fClasspathViewer

protected org.eclipse.jdt.internal.debug.ui.classpath.RuntimeClasspathViewer fClasspathViewer

fModel

private org.eclipse.jdt.internal.debug.ui.classpath.ClasspathModel fModel

DIALOG_SETTINGS_PREFIX

protected static final java.lang.String DIALOG_SETTINGS_PREFIX
See Also:
Constant Field Values

fLaunchConfiguration

protected org.eclipse.debug.core.ILaunchConfiguration fLaunchConfiguration
The last launch config this tab was initialized from

Constructor Detail

JavaClasspathTab

public JavaClasspathTab()
Method Detail

createControl

public void createControl(org.eclipse.swt.widgets.Composite parent)
Description copied from interface: org.eclipse.debug.ui.ILaunchConfigurationTab
Creates the top level control for this launch configuration tab under the given parent composite. This method is called once on tab creation, after setLaunchConfigurationDialog is called.

Implementors are responsible for ensuring that the created control can be accessed via getControl


createPathButtons

protected void createPathButtons(org.eclipse.swt.widgets.Composite pathButtonComp)
Creates the buttons to manipulate the classpath.

Since:
3.0

createButton

protected org.eclipse.swt.widgets.Button createButton(org.eclipse.swt.widgets.Composite pathButtonComp,
                                                      org.eclipse.jdt.internal.debug.ui.actions.RuntimeClasspathAction action)
Creates a button for the given action.


setDefaults

public void setDefaults(org.eclipse.debug.core.ILaunchConfigurationWorkingCopy configuration)
Description copied from interface: org.eclipse.debug.ui.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.


initializeFrom

public void initializeFrom(org.eclipse.debug.core.ILaunchConfiguration configuration)
Description copied from interface: org.eclipse.debug.ui.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.


activated

public void activated(org.eclipse.debug.core.ILaunchConfigurationWorkingCopy workingCopy)
Description copied from class: org.eclipse.debug.ui.AbstractLaunchConfigurationTab
This method was added to the ILaunchConfigurationTab 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's initializeFrom method. Tabs should override this method as required.

The launch tab framework was originially 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 and deactivated allow tabs to determine the appropriate course of action.


refresh

private void refresh(org.eclipse.debug.core.ILaunchConfiguration configuration)
Refreshes the classpath entries based on the current state of the given launch configuration.


createClasspathModel

private void createClasspathModel(org.eclipse.debug.core.ILaunchConfiguration configuration)
                           throws org.eclipse.core.runtime.CoreException

performApply

public void performApply(org.eclipse.debug.core.ILaunchConfigurationWorkingCopy configuration)
Description copied from interface: org.eclipse.debug.ui.ILaunchConfigurationTab
Copies values from this tab into the given launch configuration.


getCurrentClasspath

private org.eclipse.jdt.launching.IRuntimeClasspathEntry[] getCurrentClasspath()
Returns the classpath entries currently specified by this tab.


isDefaultClasspath

private boolean isDefaultClasspath(org.eclipse.jdt.launching.IRuntimeClasspathEntry[] classpath,
                                   org.eclipse.debug.core.ILaunchConfiguration configuration)
Returns whether the specified classpath is equivalent to the default classpath for this configuration.


getName

public java.lang.String getName()
Description copied from interface: org.eclipse.debug.ui.ILaunchConfigurationTab
Returns the name of this tab.


getClasspathImage

public static org.eclipse.swt.graphics.Image getClasspathImage()

setLaunchConfiguration

private void setLaunchConfiguration(org.eclipse.debug.core.ILaunchConfiguration config)
Sets the launch configuration for this classpath tab


getLaunchConfiguration

public org.eclipse.debug.core.ILaunchConfiguration getLaunchConfiguration()
Returns the current launch configuration


dispose

public void dispose()
Description copied from class: org.eclipse.debug.ui.AbstractLaunchConfigurationTab
By default, do nothing.


getImage

public org.eclipse.swt.graphics.Image getImage()
Description copied from interface: org.eclipse.debug.ui.ILaunchConfigurationTab
Returns the image for this tab, or null if none


isValid

public boolean isValid(org.eclipse.debug.core.ILaunchConfiguration launchConfig)
Description copied from interface: org.eclipse.debug.ui.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.


isShowBootpath

public boolean isShowBootpath()
Returns whether the bootpath should be displayed.

Since:
3.0

getModel

protected org.eclipse.jdt.internal.debug.ui.classpath.ClasspathModel getModel()