Package org.fusesource.ide.server.karaf.core.runtime

Examples of org.fusesource.ide.server.karaf.core.runtime.IKarafRuntime


   */
  @Override
  protected void doConfigure(ILaunchConfigurationWorkingCopy workingCopy)
      throws CoreException {

    IKarafRuntime runtime = null;
    if (server.getRuntime() != null) {
      runtime = (IKarafRuntime)server.getRuntime().loadAdapter(IKarafRuntime.class, null);
    }
   
    if (runtime != null) {
      String karafInstallDir = runtime.getLocation().toOSString();
      String mainProgram = null;
      String vmArguments = null;
     
      String version = runtime.getVersion();
      if (version != null) {
        if (version.startsWith(IFabric8ToolingConstants.FABRIC8_VERSION_1x)) {
          // handle 4x specific program arguments
          vmArguments = getVMArguments(karafInstallDir);
          mainProgram = getMainProgram();
View Full Code Here


    public KarafJREComposite(Composite parent, int style, TaskModel tm) {
      super(parent, style, tm);
    }   
    protected boolean isUsingDefaultJRE(IRuntime rt) {
      IRuntime r = getRuntimeFromTaskModel();
      IKarafRuntime jbsrt = (IKarafRuntime)r.loadAdapter(IKarafRuntime.class, null);
      return jbsrt.isUsingDefaultJRE();
    }
View Full Code Here

      return jbsrt.isUsingDefaultJRE();
    }
   
    protected IVMInstall getStoredJRE(IRuntime rt) {
      IRuntime r = getRuntimeFromTaskModel();
      IKarafRuntime jbsrt = (IKarafRuntime)r.loadAdapter(IKarafRuntime.class, null);
      return jbsrt.isUsingDefaultJRE() ? null : jbsrt.getVM();
    }
View Full Code Here

      return jbsrt.isUsingDefaultJRE() ? null : jbsrt.getVM();
    }

    public List<IVMInstall> getValidJREs() {
      IRuntime r = getRuntimeFromTaskModel();
      IKarafRuntime jbsrt = (IKarafRuntime)r.loadAdapter(IKarafRuntime.class, null);
      return Arrays.asList(jbsrt.getValidJREs());
    }
View Full Code Here

    protected IRuntime getRuntimeFromTaskModel() {
      return (IRuntime) getTaskModel().getObject(TaskModel.TASK_RUNTIME);
    }
    protected boolean isUsingDefaultJRE() {
      IRuntime r = getRuntimeFromTaskModel();
      IKarafRuntime jbsrt = (IKarafRuntime)r.loadAdapter(IKarafRuntime.class, null);
      return jbsrt.isUsingDefaultJRE();
    }
View Full Code Here

      return jbsrt.isUsingDefaultJRE();
    }
   
    protected IVMInstall getStoredJRE() {
      IRuntime r = getRuntimeFromTaskModel();
      IKarafRuntime jbsrt = (IKarafRuntime)r.loadAdapter(IKarafRuntime.class, null);
      return ((KarafRuntimeDelegate)jbsrt).getHardVM();
    }
View Full Code Here

      return ((KarafRuntimeDelegate)jbsrt).getHardVM();
    }
    @Override
    public IExecutionEnvironment getMinimumExecutionEnvironment() {
      IRuntime r = getRuntimeFromTaskModel();
      IKarafRuntime jbsrt = (IKarafRuntime)r.loadAdapter(IKarafRuntime.class, null);
      return jbsrt.getMinimumExecutionEnvironment();
    }
View Full Code Here

      return jbsrt.getMinimumExecutionEnvironment();
    }
    @Override
    public IExecutionEnvironment getStoredExecutionEnvironment() {
      IRuntime r = getRuntimeFromTaskModel();
      IKarafRuntime jbsrt = (IKarafRuntime)r.loadAdapter(IKarafRuntime.class, null);
      return jbsrt.getExecutionEnvironment();
    }
View Full Code Here

  protected void populateModel() {
    IRuntimeWorkingCopy workingCopy = getRuntimeWorkingCopy();
    if (workingCopy != null) {
      // workCopy will be instance of ServerDelegate classs.
      // We need to get the params, so IFuseESBRuntime will be enough.
      IKarafRuntime karafRuntime = (IKarafRuntime) workingCopy
          .loadAdapter(IKarafRuntime.class, new NullProgressMonitor());
      if (karafRuntime != null) {
        IPath loc = karafRuntime.getLocation();
        model.setKarafInstallDir(loc == null ? null : loc.toOSString());
      }
    }
  }
View Full Code Here

        model.setPassword(karafServerWorkingCopy.getPassword());
      }
      boolean readFromConfFile = false;
      IRuntime runtime = getRuntimeWorkingCopy();
      if (runtime != null){
        IKarafRuntime karafRuntime = (IKarafRuntime)runtime.loadAdapter(IKarafRuntime.class, null);
        if (karafRuntime != null ) {
          if("".equals(model.getKarafInstallDir()) || model.getKarafInstallDir() == null){
            model.setKarafInstallDir(karafRuntime.getLocation().toOSString());
          }
        }
      }
      if (!readFromConfFile && karafServerWorkingCopy != null) {
        model.setPortNumber(karafServerWorkingCopy.getPortNumber());
View Full Code Here

TOP

Related Classes of org.fusesource.ide.server.karaf.core.runtime.IKarafRuntime

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.