aboutsummaryrefslogtreecommitdiff
path: root/src/lux/host.clj
diff options
context:
space:
mode:
authorEduardo Julian2015-09-12 19:00:56 -0400
committerEduardo Julian2015-09-12 19:00:56 -0400
commit45a102bae3707d1a5220d7e124221ed46882f22d (patch)
tree057b24eac5513803bc3b0c0c84af00ec0ad37a4c /src/lux/host.clj
parent1e5f1afbd0f8b54350e552c110dead87b4b5dca0 (diff)
- Added exhaustiveness testing for class definition.
Diffstat (limited to '')
-rw-r--r--src/lux/host.clj5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/lux/host.clj b/src/lux/host.clj
index 81323b1d8..8d6135d64 100644
--- a/src/lux/host.clj
+++ b/src/lux/host.clj
@@ -134,5 +134,10 @@
(return &type/Unit)
(fail (str "[Host Error] Constructor does not exist: " target))))
+(defn abstract-methods [class-loader class]
+ (return (&/->list (for [^Method =method (.getDeclaredMethods (Class/forName (&type/as-obj class) true class-loader))
+ :when (.equals true (Modifier/isAbstract (.getModifiers =method)))]
+ (&/T (.getName =method) (&/|map #(.getName ^Class %) (&/->list (seq (.getParameterTypes =method)))))))))
+
(defn location [scope]
(->> scope (&/|map &/normalize-name) (&/|interpose "$") (&/fold str "")))