From 5a4d23457a4542d71e78adfc95dac675fe9a8d58 Mon Sep 17 00:00:00 2001 From: Karson Date: Fri, 5 Jan 2024 17:58:43 +0800 Subject: [PATCH] add anno for some interface (#1048) --- .../src/main/java/com/alipay/sofa/jraft/entity/Checksum.java | 1 + .../src/main/java/com/alipay/sofa/jraft/util/Copiable.java | 1 + .../main/java/com/alipay/sofa/jraft/util/JRaftSignalHandler.java | 1 + .../src/main/java/com/alipay/sofa/jraft/util/Recyclable.java | 1 + 4 files changed, 4 insertions(+) diff --git a/jraft-core/src/main/java/com/alipay/sofa/jraft/entity/Checksum.java b/jraft-core/src/main/java/com/alipay/sofa/jraft/entity/Checksum.java index 58444ff74..035474aa5 100644 --- a/jraft-core/src/main/java/com/alipay/sofa/jraft/entity/Checksum.java +++ b/jraft-core/src/main/java/com/alipay/sofa/jraft/entity/Checksum.java @@ -24,6 +24,7 @@ * @author boyan(boyan@antfin.com) * @since 1.2.6 */ +@FunctionalInterface public interface Checksum { /** diff --git a/jraft-core/src/main/java/com/alipay/sofa/jraft/util/Copiable.java b/jraft-core/src/main/java/com/alipay/sofa/jraft/util/Copiable.java index ecef0c8b7..1d2fbe3a7 100644 --- a/jraft-core/src/main/java/com/alipay/sofa/jraft/util/Copiable.java +++ b/jraft-core/src/main/java/com/alipay/sofa/jraft/util/Copiable.java @@ -24,6 +24,7 @@ * 2018-Apr-03 11:15:34 AM * @param */ +@FunctionalInterface public interface Copiable { /** diff --git a/jraft-core/src/main/java/com/alipay/sofa/jraft/util/JRaftSignalHandler.java b/jraft-core/src/main/java/com/alipay/sofa/jraft/util/JRaftSignalHandler.java index fa46cef08..c1a64e90c 100644 --- a/jraft-core/src/main/java/com/alipay/sofa/jraft/util/JRaftSignalHandler.java +++ b/jraft-core/src/main/java/com/alipay/sofa/jraft/util/JRaftSignalHandler.java @@ -20,6 +20,7 @@ * * @author jiachun.fjc */ +@FunctionalInterface public interface JRaftSignalHandler { void handle(final String signalName); diff --git a/jraft-core/src/main/java/com/alipay/sofa/jraft/util/Recyclable.java b/jraft-core/src/main/java/com/alipay/sofa/jraft/util/Recyclable.java index 8c25a377b..9e5dea973 100644 --- a/jraft-core/src/main/java/com/alipay/sofa/jraft/util/Recyclable.java +++ b/jraft-core/src/main/java/com/alipay/sofa/jraft/util/Recyclable.java @@ -20,6 +20,7 @@ * * @author jiachun.fjc */ +@FunctionalInterface public interface Recyclable { /**