1.2.0 permalink Arrow_down_16x16

new-by-name

clojure.contrib.core

  • (new-by-name class-name & args)
Constructs a Java object whose class is specified by a String.

0 Examples top

Log in to add / edit an example.

See Also top

Log in to add a see also.

Plus_12x12 Minus_12x12 Source clojure/contrib/core.clj:71 top

(defn new-by-name
  "Constructs a Java object whose class is specified by a String."
  [class-name & args]
  (clojure.lang.Reflector/invokeConstructor
   (clojure.lang.RT/classForName class-name)
   (into-array Object args)))
Vars in clojure.contrib.core/new-by-name: defn into-array
Used in 0 other vars

Comments top

No comments for new-by-name. Log in to add a comment.