Package org.eclipse.debug.core

Examples of org.eclipse.debug.core.ILaunchConfigurationType


   
  }
  protected static ILaunch launch(IProject proj, String name, String mainClass, String args, String vmargs, String app) throws CoreException
    ILaunchManager manager = DebugPlugin.getDefault().getLaunchManager();
 
    ILaunchConfigurationType type=null;
    if(app.equalsIgnoreCase(CommonNames.START_DERBY_SERVER)){
      //type= manager.getLaunchConfigurationType("org.apache.derby.ui.startDerbyServerLaunchConfigurationType");
      type= manager.getLaunchConfigurationType(CommonNames.START_SERVER_LAUNCH_CONFIG_TYPE);
    }else if(app.equalsIgnoreCase(CommonNames.SHUTDOWN_DERBY_SERVER)){
      //type= manager.getLaunchConfigurationType("org.apache.derby.ui.stopDerbyServerLaunchConfigurationType");
      type= manager.getLaunchConfigurationType(CommonNames.STOP_SERVER_LAUNCH_CONFIG_TYPE);
    }else if(app.equalsIgnoreCase(CommonNames.IJ)){
      //type= manager.getLaunchConfigurationType("org.apache.derby.ui.ijDerbyLaunchConfigurationType");
      type= manager.getLaunchConfigurationType(CommonNames.IJ_LAUNCH_CONFIG_TYPE);
    }else if(app.equalsIgnoreCase(CommonNames.SYSINFO)){
      //type= manager.getLaunchConfigurationType("org.apache.derby.ui.sysinfoDerbyLaunchConfigurationType");
      type= manager.getLaunchConfigurationType(CommonNames.SYSINFO_LAUNCH_CONFIG_TYPE);
    }else{
      type = manager.getLaunchConfigurationType(IJavaLaunchConfigurationConstants.ID_JAVA_APPLICATION);
    }
    ILaunchConfiguration config = null;
    // if the configuration already exists, delete it
    ILaunchConfiguration[] configurations = manager.getLaunchConfigurations(type);
    for (int i = 0; i < configurations.length; i++) {
      if (configurations[i].getName().equals(name))
        configurations[i].delete();
    }
    // else create a new one
    if (config == null) {
      ILaunchConfigurationWorkingCopy wc = type.newInstance(null, name);
      wc.setAttribute(IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME,
        proj.getProject().getName());
      // current directory should be the project root
      wc.setAttribute(IJavaLaunchConfigurationConstants.ATTR_WORKING_DIRECTORY,
        proj.getProject().getLocation().toString());
View Full Code Here


  }
   
  private ILaunchConfiguration[] getLaunchConfigurations() throws CoreException {
    ArrayList<ILaunchConfiguration> result = new ArrayList<ILaunchConfiguration>();
    ILaunchManager manager = DebugPlugin.getDefault().getLaunchManager();
    ILaunchConfigurationType type = manager.getLaunchConfigurationType(EclipseLaunchShortcut.CONFIGURATION_TYPE);
    ILaunchConfiguration[] configs = manager.getLaunchConfigurations(type);
    for (int i = 0; i < configs.length; i++) {
      if (!DebugUITools.isPrivate(configs[i])) {
        String foundName = configs[i].getAttribute(IToolLaunchConstants.PLAN_NAME, ""); //$NON-NLS-1$
        if (this.planName.equalsIgnoreCase(foundName)) {
View Full Code Here

    }
    return (ILaunchConfiguration[]) result.toArray(new ILaunchConfiguration[result.size()]);
  }

  private ILaunchConfiguration createConfiguration() throws CoreException {
    ILaunchConfigurationType configType = getWorkbenchLaunchConfigType();
    String computedName = getComputedName(this.planName);
    ILaunchConfigurationWorkingCopy wc = configType.newInstance(null, computedName);
    IProject project = this.plan.getProject();
    setAttributes(wc, project);
    return refreshConfiguration(wc);
  }
View Full Code Here

 
 
  private static ILaunchConfiguration createLaunch(String moduleName, String projectName) throws CoreException {
   
    ILaunchManager launchManager = DebugPlugin.getDefault().getLaunchManager();
    ILaunchConfigurationType configType = launchManager.getLaunchConfigurationType(Constants.LAUNCH_CONFIG_TYPE);
    ILaunchConfigurationWorkingCopy copy = configType.newInstance(null, launchManager.generateUniqueLaunchConfigurationNameFrom(moduleName));
    copy.setAttribute(Constants.LAUNCH_ATTR_MODULE_NAME, moduleName);
    copy.setAttribute(IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, projectName);
    copy.setAttribute(Constants.LAUNCH_ATTR_PROJECT_NAME, projectName);
   
    return copy.doSave();
View Full Code Here


  public static ILaunchConfiguration findLaunch(String moduleName, String projectName) throws CoreException {
   
    ILaunchManager launchManager = DebugPlugin.getDefault().getLaunchManager();
    ILaunchConfigurationType configType = launchManager.getLaunchConfigurationType(Constants.LAUNCH_CONFIG_TYPE);
    ILaunchConfiguration[] launchConfigurations = launchManager.getLaunchConfigurations(configType);
    ILaunchConfiguration toLaunch = null;

    for (int i = 0; i < launchConfigurations.length; i++) {
      ILaunchConfiguration configuration = launchConfigurations[i];
View Full Code Here

  }

  private static ILaunchConfiguration createLaunch(String moduleName, String projectName) throws CoreException {

    ILaunchManager launchManager = DebugPlugin.getDefault().getLaunchManager();
    ILaunchConfigurationType configType = launchManager.getLaunchConfigurationType(Constants.LAUNCH_CONFIG_TYPE);
    ILaunchConfigurationWorkingCopy copy = configType.newInstance(null, launchManager.generateUniqueLaunchConfigurationNameFrom(moduleName));
    copy.setAttribute(Constants.LAUNCH_ATTR_MODULE_NAME, moduleName);
    copy.setAttribute(IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, projectName);
    copy.setAttribute(Constants.LAUNCH_ATTR_PROJECT_NAME, projectName);

    return copy.doSave();
View Full Code Here

  }

  public static ILaunchConfiguration findLaunch(String moduleName, String projectName) throws CoreException {

    ILaunchManager launchManager = DebugPlugin.getDefault().getLaunchManager();
    ILaunchConfigurationType configType = launchManager.getLaunchConfigurationType(Constants.LAUNCH_CONFIG_TYPE);
    ILaunchConfiguration[] launchConfigurations = launchManager.getLaunchConfigurations(configType);
    ILaunchConfiguration toLaunch = null;

    for (int i = 0; i < launchConfigurations.length; i++) {
      ILaunchConfiguration configuration = launchConfigurations[i];
View Full Code Here

   * @throws CoreException
   *             if something goes wrong.
   */
  public void createLaunchConfiguration(String mainHtml) throws CoreException {

    ILaunchConfigurationType type = getLaunchManager()
        .getLaunchConfigurationType(WEB_APP_TYPE);

    ILaunchConfigurationWorkingCopy config = type.newInstance(getProject()
        .getFolder(LAUNCH_CONFIGURATIONS_DIR), mainHtml);

    // Performs the configuration.
    config.setAttribute(ILaunchConfigurationConstants.IS_INTERNAL_BROWSER,
        true);
View Full Code Here

          "Previous launch has not been terminated.");
    }

    ILaunchManager mgr = getLaunchManager();

    ILaunchConfigurationType type = mgr
        .getLaunchConfigurationType(WEB_APP_TYPE);

    ILaunchConfiguration configs[] = mgr.getLaunchConfigurations(type);
    for (ILaunchConfiguration config : configs) {
      if (config.getName().equalsIgnoreCase(configName)) {
View Full Code Here

 
 
  private static ILaunchConfiguration createLaunch(String moduleName, String projectName) throws CoreException {
   
    ILaunchManager launchManager = DebugPlugin.getDefault().getLaunchManager();
    ILaunchConfigurationType configType = launchManager.getLaunchConfigurationType(Constants.LAUNCH_CONFIG_TYPE);
    ILaunchConfigurationWorkingCopy copy = configType.newInstance(null, launchManager.generateUniqueLaunchConfigurationNameFrom(moduleName));
    copy.setAttribute(Constants.LAUNCH_ATTR_MODULE_NAME, moduleName);
    copy.setAttribute(IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, projectName);
    copy.setAttribute(Constants.LAUNCH_ATTR_PROJECT_NAME, projectName);
   
    return copy.doSave();
View Full Code Here

TOP

Related Classes of org.eclipse.debug.core.ILaunchConfigurationType

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.