diff options
author | sebdet <sebastien.determe@intl.att.com> | 2018-12-11 12:42:07 +0100 |
---|---|---|
committer | sebdet <sebastien.determe@intl.att.com> | 2018-12-11 12:42:07 +0100 |
commit | 27d3e6c2b963be95f11a9aebb12de6e5028c8cb9 (patch) | |
tree | ab484032cbba84cea976af4a299fd571389a6262 /src/main/java/org | |
parent | a664994195fe5af803c2d9ceb0a8b79bca21d426 (diff) |
Reformating code
Some reformating of the code
Issue-ID: CLAMP-252
Change-Id: I68e011ed496b853d51d242f90b6382a624b08d92
Signed-off-by: sebdet <sebastien.determe@intl.att.com>
Diffstat (limited to 'src/main/java/org')
-rw-r--r-- | src/main/java/org/onap/clamp/clds/client/req/policy/GuardPolicyAttributesConstructor.java | 5 | ||||
-rw-r--r-- | src/main/java/org/onap/clamp/clds/exception/BadRequestException.java | 6 |
2 files changed, 5 insertions, 6 deletions
diff --git a/src/main/java/org/onap/clamp/clds/client/req/policy/GuardPolicyAttributesConstructor.java b/src/main/java/org/onap/clamp/clds/client/req/policy/GuardPolicyAttributesConstructor.java index afef5919c..f15d33df2 100644 --- a/src/main/java/org/onap/clamp/clds/client/req/policy/GuardPolicyAttributesConstructor.java +++ b/src/main/java/org/onap/clamp/clds/client/req/policy/GuardPolicyAttributesConstructor.java @@ -35,7 +35,6 @@ import org.onap.clamp.clds.model.properties.ModelProperties; import org.onap.clamp.clds.model.properties.PolicyChain; import org.onap.clamp.clds.model.properties.PolicyItem; import org.onap.policy.api.AttributeType; -import org.onap.policy.api.RuleProvider; public class GuardPolicyAttributesConstructor { public static final String ACTOR = "actor"; @@ -79,10 +78,10 @@ public class GuardPolicyAttributesConstructor { matchingAttributes.put(RECIPE, policyItem.getRecipe()); matchingAttributes.put(TARGETS, policyItem.getGuardTargets()); matchingAttributes.put(CLNAME, modelProp.getControlNameAndPolicyUniqueId()); - if (RuleProvider.GUARD_MIN_MAX.equals(RuleProvider.valueOf(policyItem.getGuardPolicyType()))) { + if ("GUARD_MIN_MAX".equals(policyItem.getGuardPolicyType())) { matchingAttributes.put(MIN, policyItem.getMinGuard()); matchingAttributes.put(MAX, policyItem.getMaxGuard()); - } else if (RuleProvider.GUARD_YAML.equals(RuleProvider.valueOf(policyItem.getGuardPolicyType()))) { + } else if ("GUARD_YAML".equals(policyItem.getGuardPolicyType())) { matchingAttributes.put(LIMIT, policyItem.getLimitGuard()); matchingAttributes.put(TIME_WINDOW, policyItem.getTimeWindowGuard()); matchingAttributes.put(TIME_UNITS, policyItem.getTimeUnitsGuard()); diff --git a/src/main/java/org/onap/clamp/clds/exception/BadRequestException.java b/src/main/java/org/onap/clamp/clds/exception/BadRequestException.java index 14d14a44d..c6b0d5556 100644 --- a/src/main/java/org/onap/clamp/clds/exception/BadRequestException.java +++ b/src/main/java/org/onap/clamp/clds/exception/BadRequestException.java @@ -47,9 +47,9 @@ public class BadRequestException extends RuntimeException { } /** - * This constructor can be used to create a new CldsConfigException. Use - * this constructor only if you are creating a new exception stack, not if - * an exception was already raised by another code. + * This constructor can be used to create a new CldsConfigException. Use this + * constructor only if you are creating a new exception stack, not if an + * exception was already raised by another code. * * @param message * A string message detailing the problem |