X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;ds=sidebyside;f=ECOMP-REST%2Fsrc%2Fmain%2Fjava%2Forg%2Fopenecomp%2Fpolicy%2Frest%2Fjpa%2FAttribute.java;h=f9d60ff4dbcbd592fdb15dacab47db4c793485df;hb=d9007d680d19734d5dc106479784c420236cca4b;hp=6badfa9a9a73c8a5882fc61f44f1587c69abc267;hpb=6a5e800771311208c66ad79ce1bdf76affd144b2;p=policy%2Fengine.git diff --git a/ECOMP-REST/src/main/java/org/openecomp/policy/rest/jpa/Attribute.java b/ECOMP-REST/src/main/java/org/openecomp/policy/rest/jpa/Attribute.java index 6badfa9a9..f9d60ff4d 100644 --- a/ECOMP-REST/src/main/java/org/openecomp/policy/rest/jpa/Attribute.java +++ b/ECOMP-REST/src/main/java/org/openecomp/policy/rest/jpa/Attribute.java @@ -58,10 +58,8 @@ import com.fasterxml.jackson.annotation.JsonIgnore; @NamedQuery(name="Attribute.findAll", query="SELECT a FROM Attribute a order by a.priority asc, a.xacmlId asc") public class Attribute implements Serializable { private static final long serialVersionUID = 1L; + private static final Log logger = LogFactory.getLog(Attribute.class); - public static String ATTRIBUTE_DESIGNATOR = "Attribute Designator"; - public static String ATTRIBUTE_SELECTOR = "Attribute Selector"; - @Id @GeneratedValue(strategy = GenerationType.AUTO) @Column(name="id") @@ -151,7 +149,7 @@ public class Attribute implements Serializable { this.userModifiedBy = userModifiedBy; } - private static Log LOGGER = LogFactory.getLog(Attribute.class); + public Attribute() { } @@ -159,12 +157,8 @@ public class Attribute implements Serializable { this.xacmlId = domain; } - public Attribute(String domain, String user) { - this(domain); - } - - public Attribute(Attribute copy, String user) { - this(copy.getXacmlId() + ":(0)", user); + public Attribute(Attribute copy) { + this(copy.getXacmlId() + ":(0)"); this.constraintType = copy.getConstraintType(); this.categoryBean = copy.getCategoryBean(); this.datatypeBean = copy.getDatatypeBean(); @@ -189,7 +183,7 @@ public class Attribute implements Serializable { try { this.userModifiedBy = XacmlAdminAuthorization.getUserId(); } catch (Exception e) { - LOGGER.error("Exception caused While adding Modified by Role"+e); + logger.error("Exception caused While adding Modified by Role"+e); } }