Package org.eclipse.wst.server.core

Examples of org.eclipse.wst.server.core.IRuntimeWorkingCopy.validate()


  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);
  }

  @Override
  public Composite createComposite(Composite parent, IWizardHandle wizard) {
View Full Code Here


  @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

  }

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

  @Override
  public void performFinish(IProgressMonitor monitor) throws CoreException {
View Full Code Here

     *
     * @see org.eclipse.wst.server.ui.wizard.WizardFragment#isComplete()
     */
    public boolean isComplete() {
        IRuntimeWorkingCopy runtimeWC = getRuntimeDelegate().getRuntimeWorkingCopy();
        IStatus status = runtimeWC.validate(null);
        return status == null || status.getSeverity() != IStatus.ERROR;
    }

    protected void validate() {

View Full Code Here

        if (installDir.getText() == null || installDir.getText().length() == 0) {
            // installDir field has not been entered
            wizard.setMessage(Messages.bind(Messages.installDirInfo, runtimeName), IMessageProvider.NONE);
        } else {
            IStatus status = runtimeWC.validate(null);
            if (status == null || status.isOK()) {
                // a valid install found
                wizard.setMessage(Messages.bind(Messages.serverDetected, runtimeName), IMessageProvider.NONE);
            } else if (status.getCode() == GeronimoRuntimeDelegate.INCORRECT_VERSION) {
                if (status.getSeverity() == IStatus.ERROR) {
View Full Code Here

                final IRuntimeWorkingCopy runtime = runtimeType.createRuntime(id, monitor);
                runtime.setName(directory.getName());
                runtime.setLocation(new Path(absolutePath));

                final IStatus status = runtime.validate(monitor);
                if (status == null || status.getSeverity() != IStatus.ERROR) {
                    return runtime;
                }

                // TODO: Log something?
View Full Code Here

    @Override
    public void exit() {
        final IRuntimeWorkingCopy runtime = (IRuntimeWorkingCopy) getTaskModel().getObject(
                        TaskModel.TASK_RUNTIME);

        if (runtime.validate(null).getSeverity() != IStatus.ERROR) {
            final IPath path = runtime.getLocation();

            // Save the runtime's location in the preferences area for this
            // plugin for easy retrieval
            KarafUIPluginActivator.getDefault().getPluginPreferences().setValue(
View Full Code Here

        if (runtime == null) {
            return false;
        }

        final IStatus status = runtime.validate(null);
        return (status == null || status.getSeverity() != IStatus.ERROR);
    }

}
View Full Code Here

              try {
                IRuntimeWorkingCopy runtime = rtt.createRuntime(rtt.getId(), monitor);
                // commented out the naming of the runtime as it seems to break server to runtime links
                runtime.setName(dir.getName());
                runtime.setLocation(new Path(absolutePath));
                IStatus status = runtime.validate(monitor);
                if (status == null || status.getSeverity() != IStatus.ERROR) {
                  return runtime;
                }
              } catch (Exception e) {
                Activator.getLogger().error(e);
View Full Code Here

              try {
                IRuntimeWorkingCopy runtime = rtt.createRuntime(rtt.getId(), monitor);
                // commented out the naming of the runtime as it seems to break server to runtime links
                runtime.setName(dir.getName());
                runtime.setLocation(new Path(absolutePath));
                IStatus status = runtime.validate(monitor);
                if (status == null || status.getSeverity() != IStatus.ERROR) {
                  return runtime;
                }
              } catch (Exception e) {
                Activator.getLogger().error(e);
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.