add @FunctionalInterface

This commit is contained in:
Looly
2019-10-11 18:00:55 +08:00
parent e52a282717
commit 9fa28dcb71
14 changed files with 14 additions and 0 deletions

View File

@@ -5,6 +5,7 @@ package cn.hutool.core.io;
* @author Looly * @author Looly
* *
*/ */
@FunctionalInterface
public interface LineHandler { public interface LineHandler {
/** /**
* 处理一行数据,可以编辑后存入指定地方 * 处理一行数据,可以编辑后存入指定地方

View File

@@ -12,6 +12,7 @@ package cn.hutool.core.lang;
* @param <T> 被编辑对象类型 * @param <T> 被编辑对象类型
* @author Looly * @author Looly
*/ */
@FunctionalInterface
public interface Editor<T> { public interface Editor<T> {
/** /**
* 修改过滤后的结果 * 修改过滤后的结果

View File

@@ -5,6 +5,7 @@ package cn.hutool.core.lang;
* @author Looly * @author Looly
* *
*/ */
@FunctionalInterface
public interface Filter<T> { public interface Filter<T> {
/** /**
* 是否接受对象 * 是否接受对象

View File

@@ -6,6 +6,7 @@ package cn.hutool.core.lang;
* *
* @param <T> 匹配的对象类型 * @param <T> 匹配的对象类型
*/ */
@FunctionalInterface
public interface Matcher<T>{ public interface Matcher<T>{
/** /**
* 给定对象是否匹配 * 给定对象是否匹配

View File

@@ -9,6 +9,7 @@ package cn.hutool.core.lang;
* @param <T> 被替换操作的类型 * @param <T> 被替换操作的类型
* @since 4.1.5 * @since 4.1.5
*/ */
@FunctionalInterface
public interface Replacer<T> { public interface Replacer<T> {
/** /**

View File

@@ -6,6 +6,7 @@ package cn.hutool.core.lang.copier;
* *
* @param <T> 拷贝目标类型 * @param <T> 拷贝目标类型
*/ */
@FunctionalInterface
public interface Copier<T> { public interface Copier<T> {
/** /**
* 执行拷贝 * 执行拷贝

View File

@@ -12,6 +12,7 @@ package cn.hutool.core.lang.func;
* @param <R> 返回值类型 * @param <R> 返回值类型
* @since 3.1.0 * @since 3.1.0
*/ */
@FunctionalInterface
public interface Func<P, R> { public interface Func<P, R> {
/** /**
* 执行函数 * 执行函数

View File

@@ -11,6 +11,7 @@ package cn.hutool.core.lang.func;
* @param <R> 返回值类型 * @param <R> 返回值类型
* @since 4.5.2 * @since 4.5.2
*/ */
@FunctionalInterface
public interface Func0<R> { public interface Func0<R> {
/** /**
* 执行函数 * 执行函数

View File

@@ -12,6 +12,7 @@ package cn.hutool.core.lang.func;
* @param <R> 返回值类型 * @param <R> 返回值类型
* @since 4.2.2 * @since 4.2.2
*/ */
@FunctionalInterface
public interface Func1<P, R> { public interface Func1<P, R> {
/** /**

View File

@@ -11,6 +11,7 @@ package cn.hutool.core.lang.func;
* @param <P> 参数类型 * @param <P> 参数类型
* @since 3.1.0 * @since 3.1.0
*/ */
@FunctionalInterface
public interface VoidFunc<P> { public interface VoidFunc<P> {
/** /**

View File

@@ -10,6 +10,7 @@ package cn.hutool.core.lang.func;
* *
* @since 3.2.3 * @since 3.2.3
*/ */
@FunctionalInterface
public interface VoidFunc0 { public interface VoidFunc0 {
/** /**

View File

@@ -10,6 +10,7 @@ package cn.hutool.core.lang.func;
* *
* @since 3.2.3 * @since 3.2.3
*/ */
@FunctionalInterface
public interface VoidFunc1<P> { public interface VoidFunc1<P> {
/** /**

View File

@@ -8,6 +8,7 @@ package cn.hutool.core.lang.loader;
* *
* @param <T> 对象类型 * @param <T> 对象类型
*/ */
@FunctionalInterface
public interface Loader<T> { public interface Loader<T> {
/** /**

View File

@@ -7,6 +7,7 @@ import java.util.List;
* @author looly * @author looly
* *
*/ */
@FunctionalInterface
public interface RowHandler { public interface RowHandler {
/** /**