blob: 94a1ce2183227fa053ced0f33fd6869bc666668d (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
package test.cask
import cask.model.ParamContext
object Decorated extends cask.MainRoutes{
class myDecorator extends cask.Routes.Decorator {
def getParamValues(ctx: ParamContext) = Map("extra" -> 31337)
}
@myDecorator()
@cask.get("/hello/:world")
def hello(world: String)(extra: Int) = {
world + extra
}
initialize()
}
|