Dateiverwaltung für die WebBox
ulrich
2017-03-18 1f550a4fce54040aa41f6351b0ba1fe1c404652d
src/java/de/uhilger/filecms/api/CompileService.java
@@ -54,7 +54,15 @@
  private ServletContext ctx;
  private HttpServletRequest request;
  
  public List<CompilerIssue> compile(String relPath, List fileNames) throws IOException {
  /**
   *
   * @param relPath
   * @param fileNames
   * @param mode 0 = test, 1 = build
   * @return
   * @throws IOException
   */
  public List<CompilerIssue> compile(String relPath, List fileNames, String mode) throws IOException {
    //Files[] files1 = ... ; // input for first compilation task
    //Files[] files2 = ... ; // input for second compilation task
    
@@ -79,16 +87,19 @@
    Iterable<? extends JavaFileObject> compilationUnits1 = fileManager.getJavaFileObjectsFromFiles(files);
    
    /*
    final Iterable<String> options =
            Arrays.asList(new String[]{"-Xlint",
              "-cp", project.getClassPath(),
    if( mode.equals("1")) {
      final Iterable<String> options = Arrays.asList(new String[]{"-Xlint",
              /*"-cp", project.getClassPath(),*/
              "-d", targetDir.getAbsolutePath()
              });
      compiler.getTask(null, fileManager, diagnostics, options, null, compilationUnits1).call();
    } else {
      compiler.getTask(null, null, diagnostics, null, null, compilationUnits1).call();
    }
    
    compiler.getTask(null, fileManager, diagnostics, options, null, compilationUnits1).call();
    */
    compiler.getTask(null, fileManager, diagnostics, null, null, compilationUnits1).call();
    //compiler.getTask(null, fileManager, diagnostics, null, null, compilationUnits1).call();
    /*
    Iterable<? extends JavaFileObject> compilationUnits2