Hi all,
I've written an API in Clojure to be consumed by people working in the
Java world. Now most of these people haven't even heard of Clojure;
but all they care about is 1) a working API and 2) with nice
documentation.
1) Something about the API - I tried out various things, types,
records, protocols (from the master). But finally I've decided to
stick with 2-3 defrecords + gen-class. The API is just a bunch of
static methods with zero state (earlier I was thinking fancy stuff
like OO, and keeping state for each object ... but didn't like any of
it). Anyway, so now I've a working API.
2) The problem I have now is how to put Javadocs in all my static
methods? I don't want to create documentation that is detached from
the code.
For example, if I declare a method in gen-class as -
#^{:static true} [myCoolFn [int int] clojure.lang.LazySeq]
and definition of the function-
(defn -myCoolFn
"My cool documentation"
[a b]
...
)
The .class file generated and hence the API -
2.1) Doesn't have the parameters named int a, int b :(. They are
named as int arg0, int arg1.
2.2) "My cool documentation" doesn't come up in the Javadocs.
I'm not much familiar with Java so please advise.
Thanks!
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your
first post.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en