> So I think the source of the exception is clear, but have you found a
> solution to your original problem? Maybe if you expand on that someone
> can describe a good technique.

I'm using clojure-contrib's ns-utils/ns-vars and find-namespaces/find-
namespaces-on-classpath to discover namespaces and look for typed vars
in them to be later evaled and used. Here's the main components that
are used:

 * defmytype: like the defbar example in the above post.
 * find-mytypes: a function that takes a set of namespaces or regex
expressions to search for namespaces and returns the symbols of each
instance of mytype found in them.
 * then the code may use these symbols to load one of them.

For now, I have only a partial implementation and it's not much more
useful than loading any given symbol in a try catch, but eventually I
think it could be useful to provide plugin-like capabilities without
much boilerplate. I've been working on a small project that use this
technique and will release it shortly, that will give you a better
idea.

Thanks

- budu
-- 
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

Reply via email to