Use the diamond syntax

Closes gh-1450
This commit is contained in:
diguage
2017-06-05 19:20:22 +08:00
committed by Stephane Nicoll
parent ca1e682dc4
commit c1d44d9a34
16 changed files with 23 additions and 24 deletions

View File

@@ -36,7 +36,7 @@ import org.springframework.web.servlet.HandlerExceptionResolver;
*/
class WebMvcConfigurerComposite implements WebMvcConfigurer {
private final List<WebMvcConfigurer> delegates = new ArrayList<WebMvcConfigurer>();
private final List<WebMvcConfigurer> delegates = new ArrayList<>();
public void addWebMvcConfigurers(List<WebMvcConfigurer> configurers) {

View File

@@ -340,7 +340,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
*/
@Nullable
protected HandlerMethod lookupHandlerMethod(String lookupPath, HttpServletRequest request) throws Exception {
List<Match> matches = new ArrayList<Match>();
List<Match> matches = new ArrayList<>();
List<T> directPathMatches = this.mappingRegistry.getMappingsByUrl(lookupPath);
if (directPathMatches != null) {
addMatchingMappings(directPathMatches, matches, request);