Resolve LF license header issue
[policy/engine.git] / ONAP-REST / src / main / java / org / onap / policy / rest / jpa / SystemLogDB.java
1 /*-
2  * ============LICENSE_START=======================================================
3  * ONAP-REST
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
10  * 
11  *      http://www.apache.org/licenses/LICENSE-2.0
12  * 
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=========================================================
19  */
20 package org.onap.policy.rest.jpa;
21
22 import java.io.Serializable;
23 import java.util.Date;
24
25 import javax.persistence.Column;
26 import javax.persistence.Entity;
27 import javax.persistence.GeneratedValue;
28 import javax.persistence.GenerationType;
29 import javax.persistence.Id;
30 import javax.persistence.NamedQuery;
31 import javax.persistence.Table;
32 import javax.persistence.Temporal;
33 import javax.persistence.TemporalType;
34
35 /**
36   * The persistent class for the system log database table.
37   * 
38 */
39 @Entity
40 @Table(name="SystemLogDB")
41 @NamedQuery(name="SystemLogDB.findAll", query="SELECT o FROM SystemLogDB o")
42 public class SystemLogDB implements Serializable {
43         private static final long serialVersionUID = 1L;
44
45
46         @Id
47         @GeneratedValue(strategy = GenerationType.AUTO)
48         @Column(name="id")
49         private int id;
50
51         @Column(name="type", nullable=false)
52         private String type;
53
54         @Column(name="system", nullable=false, length=255)
55         private String system;
56
57         @Column(name="description", nullable=true, length=2048)
58         private String description;
59         
60         @Column(name="remote", nullable=false, length=255)
61         private String remote;
62         
63         @Column(name="logtype", nullable=false, length=255)
64         private String logtype;
65
66         @Temporal(TemporalType.TIMESTAMP)
67         @Column(name="date", nullable=false, updatable=false)
68         private Date date;
69
70         public SystemLogDB() {
71                 super();
72         }
73         
74         public SystemLogDB(int id, String system, String description, String remote,
75                         String type, String logtype) {
76                 this.id = id;
77                 this.system = system;
78                 this.description = description;
79                 this.remote = remote;
80                 this.type = type;
81                 this.logtype = logtype;
82         }
83
84         public void SystemLogB (int id, String system, String description, String remote, String type, Date date, String logtype){
85                 this.id = id;
86                 this.system = system;
87                 this.description = description;
88                 this.remote = remote;
89                 this.type = type;
90                 this.date = date;
91                 this.logtype = logtype;
92                 
93         }
94         
95         public int getId() {
96                 return this.id;
97         }
98
99         public void setId(int id) {
100                 this.id = id;
101         }
102         
103         public Date getDate(){
104                 return this.date;
105         }
106         
107         public void setDate(Date date){
108                 this.date = date;
109         }
110
111         public String getDescription() {
112                 return this.description;
113         }
114
115         public void setDescription(String description) {
116                 this.description = description;
117         }
118
119         public String getType() {
120                 return this.type;
121         }
122
123         public void setType(String type) {
124                 this.type = type;
125                 
126         }
127
128         public String getSystem() {
129                 return this.system;
130         }
131
132         public void setSystem(String system) {
133                 this.system = system;
134         }
135         
136         public String getRemote() {
137                 return this.remote;
138         }
139
140         public void setRemote(String remote) {
141                 this.remote = remote;
142                 
143         }
144         public String getLogtype() {
145                 return this.logtype;
146         }
147
148         public void setLogtype(String logtype) {
149                 this.logtype = logtype;
150                 
151         }
152 }