Created
May 27, 2014 12:37
-
-
Save ikitommi/e84df225ab5968b7afd8 to your computer and use it in GitHub Desktop.
LocalDate coercion
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
lein try metosin/ring-swagger | |
;nREPL server started on port 62925 on host 127.0.0.1 | |
;REPL-y 0.3.0 | |
;Clojure 1.5.1 | |
user=> (require '[ring.swagger.schema :refer :all]) | |
nil | |
user=> (defmodel Neiti {:aika org.joda.time.LocalDate}) | |
#'user/Neiti | |
user=> (coerce! Neiti {:aika "2014-06-06"}) | |
{:aika #<LocalDate 2014-06-06>} | |
user=> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment