std.lib.enum
create-enum
added in 3.0
(create-enum s type)creates an enum value from a string
(create-enum “TYPE” ElementType) => ElementType/TYPE
enum-values
added in 3.0
(enum-values type)returns all values of an enum type
(->> (enum-values ElementType) (map str)) => (contains [“TYPE” “FIELD” “METHOD” “PARAMETER” “CONSTRUCTOR”] :in-any-order :gaps-ok)
enum?
added in 3.0
(enum? type)check to see if class is an enum type
(enum? java.lang.annotation.ElementType) => true
(enum? String) => false
to-enum
added in 3.0
(to-enum s type)gets an enum value given a symbol
(to-enum “TYPE” ElementType) => ElementType/TYPE
(to-enum :field ElementType) => ElementType/FIELD