I have a class that models my request, something like
class Venue {
private String city;
private String place;
// Respective getters and setters
Spring MVC offers the ability to bind request params and path variables into a JavaBean, which in your case is Venue.
For example:
@RequestMapping(value = "/venue/{city}/{place}", method = "GET")
public String getVenueDetails(Venue venue, Model model) {
// venue object will be automatically populated with city and place
}
Note that your JavaBean has to have city and place properties for it to work.
For more information, you can take a look at the withParamGroup() example from spring-projects/spring-mvc-showcase