diff options
author | Pamela Dragosh <pdragosh@research.att.com> | 2017-09-20 17:47:51 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2017-09-20 17:47:51 +0000 |
commit | 5fabbbd783389aef7795c0066e114b593137ee50 (patch) | |
tree | 3b329fb91d5d54cab6882a416b2b17f7157d230f | |
parent | ba22da2235c12f27b8edcec59fdffaf77d324753 (diff) | |
parent | a8b497dacd36b86e0accf764a0290507923be7df (diff) |
Merge "Fix for Sonar major issues"
8 files changed, 9 insertions, 1 deletions
diff --git a/PolicyEngineAPI/src/main/java/org/onap/policy/api/AttributeType.java b/PolicyEngineAPI/src/main/java/org/onap/policy/api/AttributeType.java index 8cfa51212..0a4621902 100644 --- a/PolicyEngineAPI/src/main/java/org/onap/policy/api/AttributeType.java +++ b/PolicyEngineAPI/src/main/java/org/onap/policy/api/AttributeType.java @@ -62,6 +62,7 @@ public enum AttributeType { * Returns the <code>String</code> format of Type for this <code>AttributeType</code> * @return the <code>String</code> of the Type for this <code>AttributeType</code> */ + @Override public String toString() { return this.name; } diff --git a/PolicyEngineAPI/src/main/java/org/onap/policy/api/DeletePolicyCondition.java b/PolicyEngineAPI/src/main/java/org/onap/policy/api/DeletePolicyCondition.java index 4001d3fa6..117ac716e 100644 --- a/PolicyEngineAPI/src/main/java/org/onap/policy/api/DeletePolicyCondition.java +++ b/PolicyEngineAPI/src/main/java/org/onap/policy/api/DeletePolicyCondition.java @@ -49,6 +49,7 @@ public enum DeletePolicyCondition { * Returns the <code>String</code> format of delete condition for this Policy * @return the <code>String</code> of the delete condition for this Policy */ + @Override public String toString(){ return this.name; } diff --git a/PolicyEngineAPI/src/main/java/org/onap/policy/api/DictionaryType.java b/PolicyEngineAPI/src/main/java/org/onap/policy/api/DictionaryType.java index 5ac6d5ed8..499295d65 100644 --- a/PolicyEngineAPI/src/main/java/org/onap/policy/api/DictionaryType.java +++ b/PolicyEngineAPI/src/main/java/org/onap/policy/api/DictionaryType.java @@ -83,6 +83,7 @@ public enum DictionaryType{ * Returns the <code>String</code> format of Type for this <code>PolicyClass</code> * @return the <code>String</code> of the Type for this <code>PolicyClass</code> */ + @Override public String toString() { return this.name; } diff --git a/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyClass.java b/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyClass.java index 5132a44be..6a648e8e6 100644 --- a/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyClass.java +++ b/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyClass.java @@ -52,6 +52,7 @@ public enum PolicyClass { * Returns the <code>String</code> format of Type for this <code>PolicyClass</code> * @return the <code>String</code> of the Type for this <code>PolicyClass</code> */ + @Override public String toString() { return this.name; } diff --git a/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyConfigStatus.java b/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyConfigStatus.java index 23291c9b9..cee156786 100644 --- a/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyConfigStatus.java +++ b/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyConfigStatus.java @@ -52,7 +52,7 @@ public enum PolicyConfigStatus { * if no match is found */ public static PolicyConfigStatus getStatus(String configStatus) { - if(configStatus.equalsIgnoreCase("retrieved")) { + if("retrieved".equalsIgnoreCase(configStatus)) { return CONFIG_RETRIEVED; }else { return CONFIG_NOT_FOUND; @@ -64,6 +64,7 @@ public enum PolicyConfigStatus { * * @return the <code>String</code> name for this <code>PolicyConfigStatus</code> */ + @Override public String toString(){ return this.name; } diff --git a/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyConfigType.java b/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyConfigType.java index 59fd42733..2fb5d96db 100644 --- a/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyConfigType.java +++ b/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyConfigType.java @@ -73,6 +73,7 @@ public enum PolicyConfigType{ * Returns the <code>String</code> format of Type for this <code>PolicyClass</code> * @return the <code>String</code> of the Type for this <code>PolicyClass</code> */ + @Override public String toString() { return name; } diff --git a/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyDecision.java b/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyDecision.java index b5fdc1e01..6bae84cc7 100644 --- a/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyDecision.java +++ b/PolicyEngineAPI/src/main/java/org/onap/policy/api/PolicyDecision.java @@ -53,6 +53,7 @@ public enum PolicyDecision { * * @return the <code>String</code> name for this <code>PolicyDecision</code> */ + @Override public String toString(){ return this.name; } diff --git a/PolicyEngineUtils/src/main/java/org/onap/policy/api/NotificationHandler.java b/PolicyEngineUtils/src/main/java/org/onap/policy/api/NotificationHandler.java index 6484a9d7e..837eba967 100644 --- a/PolicyEngineUtils/src/main/java/org/onap/policy/api/NotificationHandler.java +++ b/PolicyEngineUtils/src/main/java/org/onap/policy/api/NotificationHandler.java @@ -24,6 +24,7 @@ package org.onap.policy.api; * * @version 0.1 */ +@FunctionalInterface public interface NotificationHandler { /** * <code>notificationReceived</code> method will be triggered automatically whenever a Notification is received by the PEP. |