Hi,
I want to create and compile java classes on the fly using clojure.
I also want to pack the compiled result in a jar file to be used by
another system.
I have used JavaAssist before but thought that it could be kind of
neat to use clojure instead.
I have ran into a problem though:
(defn dyn-class [ns cname]
(gen-class
:name cname
:state state
:main false
:prefix "-"
:impl-ns ns
:methods [[helloGen [] void]])
(intern ns '-helloGen (fn [] (println "hello awkward world!"
(create-ns 'hejsan)
(dyn-class 'hejsan "com.dr.Allan")
(compile 'hejsan)
Could not locate hejsan__init.class or hejsan.clj on classpath:
[Thrown class java.io.FileNotFoundException]
Can I do this without having to write hejsan.clj down to disk ?
Thanks! // Olle
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en