Add @FunctionalInterface on candidate interfaces

Issue: SPR-14432
This commit is contained in:
Stephane Nicoll
2016-07-06 14:32:13 +02:00
parent 912b63ad44
commit e4b0486c5a
110 changed files with 199 additions and 84 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2014 the original author or authors.
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -37,6 +37,7 @@ import org.springframework.web.method.HandlerMethod;
* @author Rossen Stoyanchev
* @since 4.1
*/
@FunctionalInterface
public interface HandlerMethodMappingNamingStrategy<T> {
/**

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2014 the original author or authors.
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -106,6 +106,7 @@ import org.springframework.web.servlet.ModelAndView;
* @see org.springframework.web.context.ServletContextAware
* @see org.springframework.web.context.support.WebApplicationObjectSupport
*/
@FunctionalInterface
public interface Controller {
/**

View File

@@ -24,6 +24,7 @@ import org.springframework.http.server.ServerHttpResponse;
* @author Rossen Stoyanchev
* @since 4.3
*/
@FunctionalInterface
public interface ResponseBodyEmitterAdapter {
/**

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2015 the original author or authors.
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -35,6 +35,7 @@ import java.io.OutputStream;
* @author Rossen Stoyanchev
* @since 4.2
*/
@FunctionalInterface
public interface StreamingResponseBody {
/**

View File

@@ -143,7 +143,8 @@ public class AppCacheManifestTransformer extends ResourceTransformerSupport {
}
private static interface SectionTransformer {
@FunctionalInterface
private interface SectionTransformer {
/**
* Transforms a line in a section of the manifest.

View File

@@ -128,7 +128,8 @@ public class CssLinkResourceTransformer extends ResourceTransformerSupport {
}
protected static interface CssLinkParser {
@FunctionalInterface
protected interface CssLinkParser {
void parseLink(String content, Set<CssLinkInfo> linkInfos);

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2015 the original author or authors.
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -28,6 +28,7 @@ import org.springframework.core.io.Resource;
* @author Rossen Stoyanchev
* @since 4.1
*/
@FunctionalInterface
public interface ResourceTransformer {
/**