diff options
Diffstat (limited to 'policy-utils/src/main')
4 files changed, 10 insertions, 4 deletions
diff --git a/policy-utils/src/main/java/org/onap/policy/drools/utils/LoggerUtil.java b/policy-utils/src/main/java/org/onap/policy/drools/utils/LoggerUtil.java index 257d2dae..681a2b20 100644 --- a/policy-utils/src/main/java/org/onap/policy/drools/utils/LoggerUtil.java +++ b/policy-utils/src/main/java/org/onap/policy/drools/utils/LoggerUtil.java @@ -32,6 +32,10 @@ public class LoggerUtil { * Root logger */ public static final String ROOT_LOGGER = "ROOT"; + + private LoggerUtil() { + // Empty constructor + } /** * set the log level of a logger diff --git a/policy-utils/src/main/java/org/onap/policy/drools/utils/NetworkUtil.java b/policy-utils/src/main/java/org/onap/policy/drools/utils/NetworkUtil.java index bd5b8aac..6734226d 100644 --- a/policy-utils/src/main/java/org/onap/policy/drools/utils/NetworkUtil.java +++ b/policy-utils/src/main/java/org/onap/policy/drools/utils/NetworkUtil.java @@ -39,6 +39,9 @@ public class NetworkUtil { */ public static final String IPv4_WILDCARD_ADDRESS = "0.0.0.0"; + private NetworkUtil() { + // Empty constructor + } /** * try to connect to $host:$port $retries times while we are getting connection failures. diff --git a/policy-utils/src/main/java/org/onap/policy/drools/utils/OrderedService.java b/policy-utils/src/main/java/org/onap/policy/drools/utils/OrderedService.java index 75a3cd7d..7a6ca0a0 100644 --- a/policy-utils/src/main/java/org/onap/policy/drools/utils/OrderedService.java +++ b/policy-utils/src/main/java/org/onap/policy/drools/utils/OrderedService.java @@ -25,6 +25,7 @@ package org.onap.policy.drools.utils; * of services (features) discovered via 'ServiceLoader'. See * 'OrderedServiceImpl' for more details. */ +@FunctionalInterface public interface OrderedService { /** diff --git a/policy-utils/src/main/java/org/onap/policy/drools/utils/ReflectionUtil.java b/policy-utils/src/main/java/org/onap/policy/drools/utils/ReflectionUtil.java index 50135e84..bf59ec96 100644 --- a/policy-utils/src/main/java/org/onap/policy/drools/utils/ReflectionUtil.java +++ b/policy-utils/src/main/java/org/onap/policy/drools/utils/ReflectionUtil.java @@ -45,8 +45,7 @@ public class ReflectionUtil { * @throws IllegalArgumentException if an invalid parameter has been passed in */ public static Class<?> fetchClass(ClassLoader classLoader, - String className) - throws IllegalArgumentException { + String className) { if (classLoader == null) throw new IllegalArgumentException("A class loader must be provided"); @@ -70,8 +69,7 @@ public class ReflectionUtil { * @return true if exists * @throws IllegalArgumentException if an invalid parameter has been passed in */ - public static boolean isClass(ClassLoader classLoader, String classname) - throws IllegalArgumentException { + public static boolean isClass(ClassLoader classLoader, String classname) { return fetchClass(classLoader, classname) != null; } |