X-Git-Url: https://gerrit.onap.org/r/gitweb?p=portal.git;a=blobdiff_plain;f=portal-BE%2Fsrc%2Fmain%2Fjava%2Forg%2Fonap%2Fportal%2Fdomain%2Fdb%2Ffn%2FFnRole.java;h=eda3fb2668acaaccd63aac41b8785e95284bcf46;hp=dc4578832323076f5316fdc524b95bb1116fca66;hb=682a90dad9795a3fa9aaffbf43c488057b8529e7;hpb=8c6ccfe62953f28f704891c76258d595dc9d0b03 diff --git a/portal-BE/src/main/java/org/onap/portal/domain/db/fn/FnRole.java b/portal-BE/src/main/java/org/onap/portal/domain/db/fn/FnRole.java index dc457883..eda3fb26 100644 --- a/portal-BE/src/main/java/org/onap/portal/domain/db/fn/FnRole.java +++ b/portal-BE/src/main/java/org/onap/portal/domain/db/fn/FnRole.java @@ -40,8 +40,7 @@ package org.onap.portal.domain.db.fn; -import java.util.ArrayList; -import java.util.List; +import java.util.Set; import javax.persistence.CascadeType; import javax.persistence.Column; import javax.persistence.Entity; @@ -154,7 +153,7 @@ public class FnRole { cascade = CascadeType.ALL, fetch = FetchType.LAZY ) - private List fnRoleFunctions = new ArrayList<>(); + private Set fnRoleFunctions; @ManyToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY) @JoinTable( name = "fn_user_pseudo_role", @@ -164,7 +163,7 @@ public class FnRole { @Index(name = "fk_pseudo_role_user_id", columnList = "user_id") } ) - private List fnUsers = new ArrayList<>(); + private Set fnUsers; @ManyToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY) @JoinTable( name = "fn_role_composite", @@ -174,49 +173,50 @@ public class FnRole { @Index(name = "fk_fn_role_composite_child", columnList = "child_role_id") } ) - private List fnRoles = new ArrayList<>(); - @ManyToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY) - private List fnRoleList = new ArrayList<>(); + private Set fnRoles; + @ManyToMany(cascade = CascadeType.ALL, + fetch = FetchType.LAZY) + private Set fnRoleList; @OneToMany( targetEntity = EpRoleNotification.class, mappedBy = "notificationID", cascade = CascadeType.ALL, fetch = FetchType.LAZY ) - private List epRoleNotifications = new ArrayList<>(); + private Set epRoleNotifications; @OneToMany( targetEntity = FnMenuFunctionalRoles.class, mappedBy = "roleId", cascade = CascadeType.ALL, fetch = FetchType.LAZY ) - private List fnMenuFunctionalRoles = new ArrayList<>(); + private Set fnMenuFunctionalRoles; @OneToMany( targetEntity = EpWidgetCatalogRole.class, mappedBy = "roleId", cascade = CascadeType.ALL, fetch = FetchType.LAZY ) - private List epWidgetCatalogRoles = new ArrayList<>(); + private Set epWidgetCatalogRoles; @OneToMany( targetEntity = EpAppRoleFunction.class, mappedBy = "fnRole", cascade = CascadeType.ALL, fetch = FetchType.LAZY ) - private List epAppRoleFunctions = new ArrayList<>(); + private Set epAppRoleFunctions; @OneToMany( targetEntity = EpUserRolesRequestDet.class, mappedBy = "requestedRoleId", cascade = CascadeType.ALL, fetch = FetchType.LAZY ) - private List epUserRolesRequestDets = new ArrayList<>(); + private Set epUserRolesRequestDets; @OneToMany( targetEntity = FnUserRole.class, mappedBy = "roleId", cascade = CascadeType.ALL, fetch = FetchType.LAZY ) - private List fnUserRoles = new ArrayList<>(); + private Set fnUserRoles; }