Skip to content

Instantly share code, notes, and snippets.

@stevendick
Last active December 21, 2015 00:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save stevendick/6224664 to your computer and use it in GitHub Desktop.
Save stevendick/6224664 to your computer and use it in GitHub Desktop.
Spring MVC (3.2.x) controller in Clojure (1.5.1)
(ns liquidity.controller
(:import org.springframework.stereotype.Controller
(org.springframework.web.bind.annotation RequestMapping RequestMethod ResponseBody))
(:gen-class
:name ^{Controller ""} ch.hedgesphere.liquidity.controller.LiquidityController
:methods [[^{RequestMapping {:value ["/liquidity"] :method [RequestMethod/GET]} ResponseBody {}} hello [] String]]))
(defn -hello [this]
"Hello world from a Clojure-based controller!")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment