de8bef18eb344882517632a05123acc0342730ca
[ccsdk/apps.git] / ms / neng / src / main / java / org / onap / ccsdk / apps / ms / neng / persistence / entity / IdentifierMap.java
1 /*-
2  * ============LICENSE_START=======================================================
3  * ONAP : CCSDK.apps
4  * ================================================================================
5  * Copyright (C) 2018 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
21 package org.onap.ccsdk.apps.ms.neng.persistence.entity;
22
23 import java.io.Serializable;
24 import java.sql.Timestamp;
25 import javax.persistence.Column;
26 import javax.persistence.Entity;
27 import javax.persistence.Id;
28 import javax.persistence.Table;
29
30 /**
31  * Maps identifiers (such as function names) in the policy to internal names used by this
32  * micro-service.
33  */
34 @Entity
35 @Table(name = "IDENTIFIER_MAP")
36 public class IdentifierMap implements Serializable {
37
38     private static final long serialVersionUID = 1L;
39
40     Integer identifierMapId;
41     String policyFnName;
42     String jsFnName;
43     Timestamp createdTime;
44     String createdBy;
45     Timestamp lastUpdatedTime;
46     String lastUpdatedBy;
47
48     /**
49      * Primary key for this entity.
50      */
51     @Id
52     @Column(name = "IDENTIFIER_MAP_ID")
53     public Integer getIdentifierMapId() {
54         return identifierMapId;
55     }
56
57     public void setIdentifierMapId(Integer identifierMapId) {
58         this.identifierMapId = identifierMapId;
59     }
60
61     /**
62      * Name in the policy.
63      */
64     @Column(name = "POLICY_FN_NAME")
65     public String getPolicyFnName() {
66         return policyFnName;
67     }
68
69     public void setPolicyFnName(String policyFnName) {
70         this.policyFnName = policyFnName;
71     }
72
73     /**
74      * Name in this micro-service.
75      */
76     @Column(name = "JS_FN_NAME")
77     public String getJsFnName() {
78         return jsFnName;
79     }
80
81     public void setJsFnName(String jsFnName) {
82         this.jsFnName = jsFnName;
83     }
84
85     /**
86      * Time-stamp for this entity creation.
87      */
88     @Column(name = "CREATED_TIME")
89     public Timestamp getCreatedTime() {
90         return createdTime;
91     }
92
93     public void setCreatedTime(Timestamp createdTime) {
94         this.createdTime = createdTime;
95     }
96
97     /**
98      * Identifier for the entity creation.
99      */
100     @Column(name = "CREATED_BY")
101     public String getCreatedBy() {
102         return createdBy;
103     }
104
105     public void setCreatedBy(String createdBy) {
106         this.createdBy = createdBy;
107     }
108
109     /**
110      * Time-stamp for this entity update.
111      */
112     @Column(name = "LAST_UPDATED_TIME")
113     public Timestamp getLastUpdatedTime() {
114         return lastUpdatedTime;
115     }
116
117     public void setLastUpdatedTime(Timestamp lastUpdatedTime) {
118         this.lastUpdatedTime = lastUpdatedTime;
119     }
120
121     /**
122      * Identifier for this entity update.
123      */
124     @Column(name = "LAST_UPDATED_BY")
125     public String getLastUpdatedBy() {
126         return lastUpdatedBy;
127     }
128
129     public void setLastUpdatedBy(String lastUpdatedBy) {
130         this.lastUpdatedBy = lastUpdatedBy;
131     }
132 }