This question is related to calling scala code from java code.
When I include some scala library (in jar format), the return types are often of type scala.collection
and other Scala types.
When developing in Java (in Netbeans) using the scala libraries, I get the following "error" when trying to view documentation for the Scala types.
Javadoc not found. Either Javadoc documentation for this item does not exist or you have not added specified Javadoc in the Java Platform Manager or the Library Manager.
what is the best way to include javadocs (of my code and the scala-library) in the distributed jars?
If you use maven, putting a dependency on Scala should instruct the plugin to pull the javadocs (and source for the matter) from the repository. If you're not using maven for dependency management.... Well, you should start now.
BTW, exposing Scala types for Java is not a good practice. You should wrap your Scala code into standard Java. It will greatly enhance the maintainability of the code since the developers using your jars won't have to twist their heads translating Java to Scala types.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With