Beispiel #1
0
  protected void generate(StringToStringMap values, ToolHost toolHost, Interface modelItem)
      throws Exception {
    String wsimportDir =
        SoapUI.getSettings().getString(ToolsSettings.JBOSSWS_WSTOOLS_LOCATION, null);
    if (Tools.isEmpty(wsimportDir)) {
      UISupport.showErrorMessage(
          "JBossWS wstools/wsconsume directory must be set in global preferences");
      return;
    }

    String wsimportExtension = UISupport.isWindows() ? ".bat" : ".sh";

    File wscompileFile =
        new File(wsimportDir + File.separatorChar + "wsconsume" + wsimportExtension);
    if (!wscompileFile.exists()) {
      UISupport.showErrorMessage("Could not find wsconsume script at [" + wscompileFile + "]");
      return;
    }

    ProcessBuilder builder = new ProcessBuilder();
    ArgumentBuilder args = buildArgs(UISupport.isWindows(), modelItem);
    builder.command(args.getArgs());
    builder.directory(new File(wsimportDir));

    toolHost.run(new ProcessToolRunner(builder, "JBossWS wsconsume", modelItem));
  }
  protected void generate(StringToStringMap values, ToolHost toolHost, WsdlProject project)
      throws Exception {
    String wstoolsDir =
        SoapUI.getSettings().getString(ToolsSettings.JBOSSWS_WSTOOLS_LOCATION, null);
    if (Tools.isEmpty(wstoolsDir)) {
      UISupport.showErrorMessage("wstools directory must be set in global preferences");
      return;
    }

    String wsToolsExtension = UISupport.isWindows() ? ".bat" : ".sh";

    File wstoolsFile = new File(wstoolsDir + File.separatorChar + "wstools" + wsToolsExtension);
    if (!wstoolsFile.exists()) {
      UISupport.showErrorMessage("Could not find wstools script at [" + wstoolsFile + "]");
      return;
    }

    ProcessBuilder builder = new ProcessBuilder();
    ArgumentBuilder args = buildArgs(values, UISupport.isWindows());
    builder.command(args.getArgs());
    builder.directory(new File(wstoolsDir));

    toolHost.run(
        new ToolRunner(builder, new File(values.get(OUTPUT)), values.get(SERVICE_NAME), project));
  }
Beispiel #3
0
  protected void generate(StringToStringMap values, ToolHost toolHost, Interface modelItem)
      throws Exception {
    String xbDir = SoapUI.getSettings().getString(ToolsSettings.XMLBEANS_LOCATION, null);
    if (Tools.isEmpty(xbDir)) {
      UISupport.showErrorMessage("XmlBeans location must be set in global preferences");
      return;
    }

    ProcessBuilder builder = new ProcessBuilder();
    ArgumentBuilder argumentBuilder = buildArgs(values, modelItem);
    builder.command(argumentBuilder.getArgs());
    builder.directory(new File(xbDir + File.separatorChar + "bin"));

    toolHost.run(new ProcessToolRunner(builder, "XmlBeans", modelItem));
  }
  protected void generate(StringToStringMap values, ToolHost toolHost, Interface modelItem)
      throws Exception {
    String wsaDir = SoapUI.getSettings().getString(ToolsSettings.ORACLE_WSA_LOCATION, null);
    if (Tools.isEmpty(wsaDir)) {
      UISupport.showErrorMessage("wsa.jar directory must be set in global preferences");
      return;
    }

    File wsaFile = new File(wsaDir + File.separatorChar + "wsa.jar");
    if (!wsaFile.exists()) {
      UISupport.showErrorMessage("Could not find wsa.jar at [" + wsaFile + "]");
      return;
    }

    ProcessBuilder builder = new ProcessBuilder();
    ArgumentBuilder args = buildArgs(values, modelItem);
    builder.command(args.getArgs());
    builder.directory(new File(wsaDir));

    toolHost.run(new ProcessToolRunner(builder, "Oracle wsa.jar", modelItem));
  }