Re: Import java classes in clojure

2013-05-07 Thread John D. Hume
Did you try the downloads link here? http://openrules.com/jsr331/ On May 6, 2013 12:10 AM, "Caocoa" wrote: > Well, so I just tried the following commands: > >> user=> (ns mx.clojure.contemporary.pitch-centricity-and-symmetry >> #_=> (:import [jm.music.data >> #_=> Score >> #_=

Re: Import java classes in clojure

2013-05-05 Thread Caocoa
Well, so I just tried the following commands: > user=> (ns mx.clojure.contemporary.pitch-centricity-and-symmetry > #_=> (:import [jm.music.data > #_=> Score > #_=> Part > #_=> Phrase > #_=> Note]) > #_=> (:import [jm.music

Re: Import java classes in clojure

2013-05-05 Thread Caocoa
Thanks for your reply Jonathan! I copy-paste my example from a ns block, so the full code is: > user=> (ns mx.clojure.contemporary.pitch-centricity-and-symmetry > #_=> (:import [javax.constraints > #_=> Problem > #_=> ProblemFactory > #_=> Var > #_=

Re: Import java classes in clojure

2013-05-05 Thread Jonathan Fischer Friberg
(:import ...) only works in (ns ...). Outside ns, you have to use (import ...) instead (note: no ":"). See: http://blog.8thlight.com/colin-jones/2010/12/05/clojure-libs-and-namespaces-require-use-import-and-ns.html Jonathan On Mon, May 6, 2013 at 12:04 AM, Caocoa wrote: > Hi all! I'm a new C