Use the diamond syntax
Closes gh-1450
This commit is contained in:
@@ -52,7 +52,7 @@ class DefaultRenderingResponseBuilder implements RenderingResponse.Builder {
|
||||
|
||||
private final HttpHeaders headers = new HttpHeaders();
|
||||
|
||||
private final Map<String, Object> model = new LinkedHashMap<String, Object>();
|
||||
private final Map<String, Object> model = new LinkedHashMap<>();
|
||||
|
||||
|
||||
public DefaultRenderingResponseBuilder(String name) {
|
||||
|
||||
@@ -61,7 +61,7 @@ public final class HeadersRequestCondition extends AbstractRequestCondition<Head
|
||||
|
||||
|
||||
private static Collection<HeaderExpression> parseExpressions(String... headers) {
|
||||
Set<HeaderExpression> expressions = new LinkedHashSet<HeaderExpression>();
|
||||
Set<HeaderExpression> expressions = new LinkedHashSet<>();
|
||||
if (headers != null) {
|
||||
for (String header : headers) {
|
||||
HeaderExpression expr = new HeaderExpression(header);
|
||||
|
||||
@@ -301,7 +301,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
|
||||
protected HandlerMethod lookupHandlerMethod(String lookupPath, ServerWebExchange exchange)
|
||||
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, exchange);
|
||||
|
||||
Reference in New Issue
Block a user