Hi,

Am Donnerstag, 15. September 2011 23:39:10 UTC+2 schrieb Eamonn:
>
>
> The code  works BUT if I try to pass in a map for example like so 
> Object result = foo.invoke( "hello","world","#{:a 1 :b 2}"); 
>
>
This does not pass a map to the function, but the string "#{:a 1 :b 2}". And 
from your example I don't see where the class cast exception should come 
from. To create a clojure map use the normal hash-map function.

Var keyword = RT.var("clojure.core", "keyword");
Var hashMap = RT.var("clojure.core", "hash-map");

foo.invoke("hello", "world", hashMap.invoke(keyword.invoke("a"), 1, 
keyword.invoke("b"), 2));

Hope this helps.

Sincerely
Meikel

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