title: Using groovy.util.AntBuilder from java
body: <p>In groovy the groovy.util.AntBuilder can be used to eg. unzip a file into a folder:</p>
  
  <pre><code>  AntBuilder ant = new AntBuilder();
    ant.unzip(src: file.getPath(), dest: outputFolder.getPath());
  </code></pre>
  
  <p>Now I would like to do the same but from java. Its not possible to call unzip directly. I assume thats what the invokeMethod is for:</p>
  
  <pre><code>  AntBuilder ant = new AntBuilder();
    String[] args = new String[4];
    args[0] = "src";
    args[1] = file.getPath();
    args[2] = "dest";
    args[3] = outputFolder.getPath();
    ant.invokeMethod("unzip", args);
  </code></pre>
  
  <p>the above gives:</p>
  
  <pre><code> No signature of method: groovy.util.AntBuilder.unzip() is applicable for argument types: (java.lang.String, java.lang.String, java.lang.String, java.lang.String) values:
  </code></pre>
  
  <p>Any ideas?</p>
  
  <p>I have tried to google docs/examples for using the AntBuilder from java, but I have only found examples where its used from groovy.</p>