-
Notifications
You must be signed in to change notification settings - Fork 14
Context
Mario Arias edited this page Feb 22, 2016
·
13 revisions
This module add map-like support for Model
and ModelMap
So you could write this code:
@RequestMapping("/clients")
public String listClients(Model model){
model.addAttribute("clients", clientService.findAllClients());
return "clients";
}
In this way:
import org.kotlinprimavera.ui.*
@RequestMapping(array("/clients"))
public fun listClients(model: Model): String{
model["clients"] = clientService.findAllClients()
return "clients"
}
To use this module in your project
<dependency>
<groupId>org.kotlinprimavera</groupId>
<artifactId>context</artifactId>
<version>0.5</version>
</dependency>