Spring 2.0 Auto View Name Generation

Spring 2.0 will have support for autogenerating view names from a request. Rob Harrop has checked in this new strategy interface, reducing the amount of configuration required when writing Spring MVC applications.

* Strategy interface used to translate an incoming {@link javax.servlet.http.HttpServletRequest}
* into a view name when no view name is supplied by the user.
* @author Rob Harrop
* @since 2.0M2
public interface RequestToViewNameTranslator {

* Translate the incoming {@link HttpServletRequest} into a view name.
* Cannot return null.
String translate(HttpServletRequest request);

This is largely added in order to simplify working with Spring MVC.

Popular posts from this blog

Lists and arrays in Dart

Converting Array to List in Scala

Null-aware operators in Dart