Examples of IRuntimeWorkingCopy


Examples of org.eclipse.wst.server.core.IRuntimeWorkingCopy

      }
      else {
        runtime.delete();
      }
    }
    IRuntimeWorkingCopy wc = st.getRuntimeType().createRuntime(runtimeName, new SubProgressMonitor(monitor, 1));
    wc.setName(runtimeName);

    if (path != null) {
      wc.setLocation(path);
    }

    runtime = wc.save(true, new SubProgressMonitor(monitor, 1));

    return runtime;
  }
View Full Code Here

Examples of org.eclipse.wst.server.core.IRuntimeWorkingCopy

        if (launchpadRuntime == null) {
            throw new IllegalArgumentException("No runtime of type 'org.apache.sling.ide.launchpadRuntimeType' found");
        }

        IRuntimeWorkingCopy rtwc = launchpadRuntime.createRuntime("temp.sling.launchpad.rt.id",
                new NullProgressMonitor());
        rtwc.save(true, new NullProgressMonitor());

        IServerType serverType = null;
        for (IServerType type : ServerCore.getServerTypes()) {
            if ("org.apache.sling.ide.launchpadServer".equals(type.getId())) {
                serverType = type;
View Full Code Here

Examples of org.eclipse.wst.server.core.IRuntimeWorkingCopy

    return true;
  }

  @Override
  public boolean isComplete() {
    IRuntimeWorkingCopy runtime = (IRuntimeWorkingCopy) getTaskModel().getObject(TaskModel.TASK_RUNTIME);
   
    if (runtime == null)
      return false;
    IStatus status = runtime.validate(null);
    return (status == null || status.getSeverity() != IStatus.ERROR);
  }
View Full Code Here

Examples of org.eclipse.wst.server.core.IRuntimeWorkingCopy

  }

  @Override
  public void enter() {
    if (comp != null) {
      IRuntimeWorkingCopy runtime = (IRuntimeWorkingCopy) getTaskModel().getObject(TaskModel.TASK_RUNTIME);
      comp.setRuntime(runtime);
    }
  }
View Full Code Here

Examples of org.eclipse.wst.server.core.IRuntimeWorkingCopy

    }
  }

  @Override
  public void exit() {
    IRuntimeWorkingCopy runtime = (IRuntimeWorkingCopy) getTaskModel().getObject(TaskModel.TASK_RUNTIME);
    IPath path = runtime.getLocation();
    if (runtime.validate(null).getSeverity() != IStatus.ERROR)
      PEXServerPlugin.setPreference("location" + runtime.getRuntimeType().getId(), path.toString()); //$NON-NLS-1$
  }
View Full Code Here

Examples of org.eclipse.wst.server.core.IRuntimeWorkingCopy

    NullProgressMonitor mon = new NullProgressMonitor();

    IRuntimeType runtimeType = ServerCore
        .findRuntimeType("org.eclipse.wst.server.preview.runtime"); //$NON-NLS-1$

    IRuntimeWorkingCopy runtimeCopy = runtimeType.createRuntime(
        "HTTP Preview", mon); //$NON-NLS-1$

    IRuntime runtime = runtimeCopy.save(true, mon);

    IServerType serverType = ServerCore
        .findServerType("org.eclipse.wst.server.preview.server"); //$NON-NLS-1$

    IServerWorkingCopy workingCopy = serverType.createServer(
View Full Code Here

Examples of org.eclipse.wst.server.core.IRuntimeWorkingCopy

import org.eclipse.wst.server.core.IRuntimeWorkingCopy;

public class OpenEJBRuntimeClasspathProviderDelegate extends RuntimeClasspathProviderDelegate {

  protected OpenEJBRuntimeDelegate getRuntimeDelegate(IRuntime runtime) {
    IRuntimeWorkingCopy wc = runtime.createWorkingCopy();
   
    return (OpenEJBRuntimeDelegate) wc.loadAdapter(OpenEJBRuntimeDelegate.class, new NullProgressMonitor());
  }
View Full Code Here

Examples of org.eclipse.wst.server.core.IRuntimeWorkingCopy

    PlatformUI.getWorkbench().getHelpSystem().setHelp(composite, "org.apache.openejb.help.runtime");
    return composite;
  }

  protected OpenEJBRuntimeDelegate getRuntimeDelegate() {
    IRuntimeWorkingCopy wc = (IRuntimeWorkingCopy) getTaskModel().getObject(TaskModel.TASK_RUNTIME);
    if (wc == null) {
      return null;
    }
   
    return (OpenEJBRuntimeDelegate) wc.loadAdapter(OpenEJBRuntimeDelegate.class, new NullProgressMonitor());
  }
View Full Code Here

Examples of org.eclipse.wst.server.core.IRuntimeWorkingCopy

    handle.setMessage("", IMessageProvider.NONE);
  }

  @Override
  public boolean isComplete() {
    IRuntimeWorkingCopy wc = getRuntimeDelegate().getRuntimeWorkingCopy();
        IStatus status = wc.validate(null);
        return status == null || status.getSeverity() != IStatus.ERROR;
  }
View Full Code Here

Examples of org.eclipse.wst.server.core.IRuntimeWorkingCopy

  }

  private void refreshProjectsUsingThisRuntime() {
    try {
      Set<IFacetedProject> facetedProjects = ProjectFacetsManager.getFacetedProjects();
      IRuntimeWorkingCopy wc = (IRuntimeWorkingCopy) getTaskModel().getObject(TaskModel.TASK_RUNTIME);
     
      for (IFacetedProject facetedProject : facetedProjects) {
        Set<IRuntime> targetedRuntimes = facetedProject.getTargetedRuntimes();
       
        for (IRuntime runtime : targetedRuntimes) {
          if (runtime.getName().equals(wc.getName())) {
            facetedProject.removeTargetedRuntime(runtime, new NullProgressMonitor());
            facetedProject.addTargetedRuntime(runtime, new NullProgressMonitor());
           
            break;
          }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.