2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
6 * ================================================================================
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
18 * ============LICENSE_END=========================================================
21 package org.onap.policy.rest.jpa;
23 import java.io.Serializable;
25 import java.sql.Timestamp;
27 import javax.persistence.Column;
28 import javax.persistence.Entity;
29 import javax.persistence.GeneratedValue;
30 import javax.persistence.GenerationType;
31 import javax.persistence.Id;
32 import javax.persistence.NamedQuery;
33 import javax.persistence.Table;
37 * The persistent class for the roles database table.
41 @Table(name="policy_manangement")
42 @NamedQuery(name="PolicyManagement.findAll", query="SELECT r FROM PolicyManagement r")
43 public class PolicyManagement implements Serializable {
44 private static final long serialVersionUID = 1L;
47 @GeneratedValue(strategy = GenerationType.AUTO)
52 @Column(name="POLICY_NAME", nullable=false, length=45)
53 private String policyName;
55 @Column(name="scope", nullable=false, length=45)
58 @Column(name="ONAP_NAME", nullable=false, length=45)
59 private String onapName;
61 @Column(name="CONFIG_NAME", nullable=false, length=45)
62 private String configName;
64 @Column(name="XML", nullable=false)
65 private transient Clob xml;
67 @Column(name="CREATE_DATE_TIME", nullable=false)
68 private Timestamp createDateTime;
71 @Column(name="CREATED_BY", nullable=false, length=45)
72 private String createdBy;
74 @Column(name="UPDATE_DATE_TIME", nullable=false)
75 private Timestamp updateDateTime;
77 @Column(name="UPDATED_BY", nullable=false, length=45)
78 private String updatedBy;
84 public void setId(int id) {
88 public String getPolicyName() {
92 public void setPolicyName(String policyName) {
93 this.policyName = policyName;
96 public String getScope() {
100 public void setScope(String scope) {
104 public String getOnapName() {
108 public void setOnapName(String onapName) {
109 this.onapName = onapName;
112 public String getConfigName() {
116 public void setConfigName(String configName) {
117 this.configName = configName;
120 public Clob getXml() {
124 public void setXml(Clob xml) {
128 public Timestamp getCreateDateTime() {
129 return createDateTime;
132 public void setCreateDateTime(Timestamp createDateTime) {
133 this.createDateTime = createDateTime;
136 public String getCreatedBy() {
140 public void setCreatedBy(String createdBy) {
141 this.createdBy = createdBy;
144 public Timestamp getUpdateDateTime() {
145 return updateDateTime;
148 public void setUpdateDateTime(Timestamp updateDateTime) {
149 this.updateDateTime = updateDateTime;
152 public String getUpdatedBy() {
156 public void setUpdatedBy(String updatedBy) {
157 this.updatedBy = updatedBy;