You can use a simple hack based on the fact which data is on your list.
eg. you have a list of lines:
(def lst (java.util.ArrayList. ["my" "list" "of" "strings"]))
Then you can get the item type:
(if (and (instance? java.util.List lst)
(not (.isEmpty lst)))
(.getName (.getClass (.get lst 0))))
The disadvantage of this workaround is that you cannot get information about the empty b / c erase list mentioned by freakhill , but who cares about empty lists;)
Hope this helps.
domax source
share