proxy'ing a final class

2009-07-26 Thread Steffen Glückselig
Hello, I was going to extend java.util.regex.Matcher for named groups and came to a point where I wanted to proxy the Matcher-class so that my extension was usable in-place of the original implementation. I realized - via "java.lang.VerifyError: Cannot inherit from final class" - that it isn't p

add-classpath stopped working with ns:import?

2009-05-24 Thread Steffen Glückselig
I just updated from SVN resulting in some code of mine no longer working: (add-classpath "file:///C:/clojure/scripts/metadata- extractor-2.3.1.jar") (ns images.date-sorter (:import (javax.swing JFileChooser)) (:import (java.io File FilenameFilter)) (:import (java.text SimpleDateFormat))

Calling method in Java that mutates passed argument

2009-02-20 Thread Steffen Glückselig
I was trying to use Clojure to verify the behavior some method in Java. Namely I wanted to quickly check whether Collections.sort does the sorting I need. So I came up with: (let [list '("1" "KB" "K6" "2" "EÜ" "EZ" "ES")] (do (java.util.Collections/sort list) list)) But since Collect