title: Gradle javadoc doclets. Can not find doclet
body: <p>I am new to Gradle, and I am trying to use my very-own-and-beauty doclet with gradle. I have made the next task:</p>
  
  <pre><code>task myDoclet(type: Javadoc, dependsOn: myJavadocs) {
  source = sourceSets.main.allJava
  options.doclet = "com.myproject.webservice.doclets.Doclet2"
  classpath = configurations.compile  }
  </code></pre>
  
  <p>With that, I become always the next error:</p>
  
  <pre><code>javadoc: error - Cannot find doclet class com.myproject.webservice.doclets.Doclet2
  </code></pre>
  
  <p>I know that there is a options.docletpath , that should be the path to my doclet (but... src or class?), but I am not able to understand what should I put there, due to the lack of explanations in the <a href="http://gradle.org/docs/current/javadoc/org/gradle/external/javadoc/MinimalJavadocOptions.html#docletpath%28java.io.File...%29" rel="nofollow">docu</a></p>
  
  <p>Can anyone explain me how can I set correctly the doclet's path, so it finds my pretty doclet?</p>
  
  <p>Thanks for your time!!</p>