diff options
Diffstat (limited to 'utils/src/main/java/org/onap/policy/common/utils/services/FeatureApiUtils.java')
-rw-r--r-- | utils/src/main/java/org/onap/policy/common/utils/services/FeatureApiUtils.java | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/utils/src/main/java/org/onap/policy/common/utils/services/FeatureApiUtils.java b/utils/src/main/java/org/onap/policy/common/utils/services/FeatureApiUtils.java index e88361ea..042ee937 100644 --- a/utils/src/main/java/org/onap/policy/common/utils/services/FeatureApiUtils.java +++ b/utils/src/main/java/org/onap/policy/common/utils/services/FeatureApiUtils.java @@ -2,7 +2,7 @@ * ============LICENSE_START======================================================= * ONAP * ================================================================================ - * Copyright (C) 2019 AT&T Intellectual Property. All rights reserved. + * Copyright (C) 2019, 2021 AT&T Intellectual Property. All rights reserved. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -23,15 +23,14 @@ package org.onap.policy.common.utils.services; import java.util.List; import java.util.function.BiConsumer; import java.util.function.Predicate; +import lombok.AccessLevel; +import lombok.NoArgsConstructor; /** * Utilities for use with "feature APIs". */ -public class FeatureApiUtils { - - private FeatureApiUtils() { - // do nothing - } +@NoArgsConstructor(access = AccessLevel.PRIVATE) +public final class FeatureApiUtils { /** * Applies a function on each feature provider, stopping as soon as one returns true. @@ -44,7 +43,7 @@ public class FeatureApiUtils { * otherwise */ public static <T> boolean apply(List<T> providers, Predicate<T> predicate, - BiConsumer<T,Exception> handleEx) { + BiConsumer<T, Exception> handleEx) { for (T feature : providers) { try { |