aboutsummaryrefslogtreecommitdiffstats
path: root/aai-core/src/main
diff options
context:
space:
mode:
authorLukasz Rajewski <lukasz.rajewski@t-mobile.pl>2023-08-16 12:36:00 +0000
committerGerrit Code Review <gerrit@onap.org>2023-08-16 12:36:00 +0000
commitd5a889f9661e89289344ed736600bc7222095379 (patch)
treee59f9627daf465ffb7efe4997080e326a0747210 /aai-core/src/main
parentf80d389842613bc961ae3f785580ab58f61b740a (diff)
parentbf21908f6aeac303c8e2e13cff090290e9f35886 (diff)
Merge "Refactor HttpEntryTest"
Diffstat (limited to 'aai-core/src/main')
-rw-r--r--aai-core/src/main/java/org/onap/aai/serialization/db/EdgeSerializer.java12
1 files changed, 3 insertions, 9 deletions
diff --git a/aai-core/src/main/java/org/onap/aai/serialization/db/EdgeSerializer.java b/aai-core/src/main/java/org/onap/aai/serialization/db/EdgeSerializer.java
index a5a08203..0c58717e 100644
--- a/aai-core/src/main/java/org/onap/aai/serialization/db/EdgeSerializer.java
+++ b/aai-core/src/main/java/org/onap/aai/serialization/db/EdgeSerializer.java
@@ -207,15 +207,9 @@ public class EdgeSerializer {
* @param rule the rule
*/
public void addProperties(Edge edge, EdgeRule rule) {
- Map<EdgeProperty, String> propMap = new EnumMap<>(EdgeProperty.class);
- propMap.put(EdgeProperty.CONTAINS, rule.getContains());
- propMap.put(EdgeProperty.DELETE_OTHER_V, rule.getDeleteOtherV());
- propMap.put(EdgeProperty.PREVENT_DELETE, rule.getPreventDelete());
-
- for (Entry<EdgeProperty, String> entry : propMap.entrySet()) {
- edge.property(entry.getKey().toString(), entry.getValue());
- }
-
+ edge.property(EdgeProperty.CONTAINS.toString(), rule.getContains());
+ edge.property(EdgeProperty.DELETE_OTHER_V.toString(), rule.getDeleteOtherV());
+ edge.property(EdgeProperty.PREVENT_DELETE.toString(), rule.getPreventDelete());
edge.property(EdgeField.PRIVATE.toString(), rule.isPrivateEdge());
edge.property(AAIProperties.AAI_UUID, UUID.randomUUID().toString());
}