1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
|
package org.onap.vid.model;
import org.hibernate.annotations.Type;
import org.onap.vid.job.Job;
import org.onap.portalsdk.core.domain.support.DomainVo;
import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;
import java.util.Objects;
import java.util.Set;
import java.util.UUID;
@Entity
@Table(name = "vid_service_info")
public class ServiceInfo extends DomainVo {
public void setUserId(String userId) {
this.userId = userId;
}
private UUID jobId;
private UUID templateId;
private String userId;
private Job.JobStatus jobStatus;
private Date statusModifiedDate;
private boolean hidden;
private boolean pause;
private Date deletedAt;
private String owningEntityId;
private String owningEntityName;
private String project;
private String aicZoneId;
private String aicZoneName;
private String tenantId;
private String tenantName;
private String regionId;
private String regionName;
private String serviceType;
private String subscriberName;
private String serviceInstanceId;
private String serviceInstanceName;
private String serviceModelId;
private String serviceModelName;
private String serviceModelVersion;
private Date createdBulkDate;
public ServiceInfo(){
}
public ServiceInfo(String userId, Job.JobStatus jobStatus, boolean pause, UUID jobId, UUID templateId, String owningEntityId, String owningEntityName, String project, String aicZoneId, String aicZoneName, String tenantId, String tenantName, String regionId, String regionName, String serviceType, String subscriberName, String serviceInstanceId, String serviceInstanceName, String serviceModelId, String serviceModelName, String serviceModelVersion, Date createdBulkDate) {
this.userId = userId;
this.jobStatus = jobStatus;
this.jobId = jobId;
this.templateId = templateId;
this.pause = pause;
this.owningEntityId = owningEntityId;
this.owningEntityName = owningEntityName;
this.project = project;
this.aicZoneId = aicZoneId;
this.aicZoneName = aicZoneName;
this.tenantId = tenantId;
this.tenantName = tenantName;
this.regionId = regionId;
this.regionName = regionName;
this.serviceType = serviceType;
this.subscriberName = subscriberName;
this.serviceInstanceId = serviceInstanceId;
this.serviceInstanceName = serviceInstanceName;
this.serviceModelId = serviceModelId;
this.serviceModelName = serviceModelName;
this.serviceModelVersion = serviceModelVersion;
this.createdBulkDate = createdBulkDate;
}
@Column(name = "JOB_ID", columnDefinition = "CHAR(36)")
@Type(type="org.hibernate.type.UUIDCharType")
public UUID getJobId() {
return jobId;
}
@Column(name = "TEMPLATE_ID", columnDefinition = "CHAR(36)")
@Type(type="org.hibernate.type.UUIDCharType")
public UUID getTemplateId() {
return templateId;
}
@Column(name="USER_ID")
public String getUserId() {
return userId;
}
@Column(name="JOB_STATUS")
@Enumerated(EnumType.STRING)
public Job.JobStatus getJobStatus() {
return jobStatus;
}
@Column(name="STATUS_MODIFIED_DATE")
public Date getStatusModifiedDate() {
return statusModifiedDate;
}
@Column(name="IS_HIDDEN")
public boolean isHidden() {
return hidden;
}
@Column(name="IS_PAUSE")
public boolean isPause() {
return pause;
}
@Column(name="OWNING_ENTITY_ID")
public String getOwningEntityId() {
return owningEntityId;
}
@Column(name="OWNING_ENTITY_NAME")
public String getOwningEntityName() {
return owningEntityName;
}
@Column(name="PROJECT")
public String getProject() {
return project;
}
@Column(name="AIC_ZONE_ID")
public String getAicZoneId() {
return aicZoneId;
}
@Column(name="AIC_ZONE_NAME")
public String getAicZoneName() {
return aicZoneName;
}
@Column(name="TENANT_ID")
public String getTenantId() {
return tenantId;
}
@Column(name="TENANT_NAME")
public String getTenantName() {
return tenantName;
}
@Column(name="REGION_ID")
public String getRegionId() {
return regionId;
}
@Column(name="REGION_NAME")
public String getRegionName() {
return regionName;
}
@Column(name="SERVICE_TYPE")
public String getServiceType() {
return serviceType;
}
@Column(name="SUBSCRIBER_NAME")
public String getSubscriberName() {
return subscriberName;
}
@Column(name="SERVICE_INSTANCE_ID")
public String getServiceInstanceId() {
return serviceInstanceId;
}
@Column(name="SERVICE_INSTANCE_NAME")
public String getServiceInstanceName() {
return serviceInstanceName;
}
@Column(name="SERVICE_MODEL_ID")
public String getServiceModelId() {
return serviceModelId;
}
@Column(name="SERVICE_MODEL_NAME")
public String getServiceModelName() {
return serviceModelName;
}
@Column(name="SERVICE_MODEL_VERSION")
public String getServiceModelVersion() {
return serviceModelVersion;
}
@Column(name="CREATED_BULK_DATE")
public Date getCreatedBulkDate() {
return createdBulkDate;
}
@Column(name="DELETED_AT")
public Date getDeletedAt() {
return deletedAt;
}
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Override
@Column(name = "ID", columnDefinition = "INT(11)")
public Long getId() {
return this.id;
}
@Override
@Column(name = "CREATED_DATE")
public Date getCreated() {
return super.getCreated();
}
@Override
@Column(name = "MODIFIED_DATE")
public Date getModified() {
return super.getModified();
}
@Override
@Transient
public Long getCreatedId() {
return super.getCreatedId();
}
@Override
@Transient
public Long getModifiedId() {
return super.getModifiedId();
}
@Override
@Transient
public Serializable getAuditUserId() {
return super.getAuditUserId();
}
@Override
@Transient
public Long getRowNum() {
return super.getRowNum();
}
@Override
@Transient
public Set getAuditTrail() {
return super.getAuditTrail();
}
public void setJobId(UUID jobId) {
this.jobId = jobId;
}
public void setTemplateId(UUID templateId) {
this.templateId = templateId;
}
public void setJobStatus(Job.JobStatus jobStatus) {
this.jobStatus = jobStatus;
}
public void setStatusModifiedDate(Date statusModifiedDate) {
this.statusModifiedDate = statusModifiedDate;
}
public void setHidden(boolean isHidden) {
hidden = isHidden;
}
public void setPause(boolean pause) {
this.pause = pause;
}
public void setOwningEntityId(String owningEntityId) {
this.owningEntityId = owningEntityId;
}
public void setOwningEntityName(String owningEntityName) {
this.owningEntityName = owningEntityName;
}
public void setProject(String project) {
this.project = project;
}
public void setAicZoneId(String aicZoneId) {
this.aicZoneId = aicZoneId;
}
public void setAicZoneName(String aicZoneName) {
this.aicZoneName = aicZoneName;
}
public void setTenantId(String tenantId) {
this.tenantId = tenantId;
}
public void setTenantName(String tenantName) {
this.tenantName = tenantName;
}
public void setRegionId(String regionId) {
this.regionId = regionId;
}
public void setRegionName(String regionName) {
this.regionName = regionName;
}
public void setServiceType(String serviceType) {
this.serviceType = serviceType;
}
public void setSubscriberName(String subscriberName) {
this.subscriberName = subscriberName;
}
public void setServiceInstanceId(String serviceInstanceId) {
this.serviceInstanceId = serviceInstanceId;
}
public void setServiceInstanceName(String serviceInstanceName) {
this.serviceInstanceName = serviceInstanceName;
}
public void setServiceModelId(String serviceModelId) {
this.serviceModelId = serviceModelId;
}
public void setServiceModelName(String serviceModelName) {
this.serviceModelName = serviceModelName;
}
public void setServiceModelVersion(String serviceModelVersion) {
this.serviceModelVersion = serviceModelVersion;
}
public void setCreatedBulkDate(Date createdBulkDate) {
this.createdBulkDate = createdBulkDate;
}
public void setDeletedAt(Date deletedAt) {
this.deletedAt = deletedAt;
}
@Override
public boolean equals(Object o) {
if (this == o) return true;
if (!(o instanceof ServiceInfo)) return false;
ServiceInfo that = (ServiceInfo) o;
return isHidden() == that.isHidden() &&
isPause() == that.isPause() &&
Objects.equals(getDeletedAt(), that.getDeletedAt()) &&
Objects.equals(getJobId(), that.getJobId()) &&
Objects.equals(getTemplateId(), that.getTemplateId()) &&
Objects.equals(getUserId(), that.getUserId()) &&
getJobStatus() == that.getJobStatus() &&
Objects.equals(getStatusModifiedDate(), that.getStatusModifiedDate()) &&
Objects.equals(getOwningEntityId(), that.getOwningEntityId()) &&
Objects.equals(getOwningEntityName(), that.getOwningEntityName()) &&
Objects.equals(getProject(), that.getProject()) &&
Objects.equals(getAicZoneId(), that.getAicZoneId()) &&
Objects.equals(getAicZoneName(), that.getAicZoneName()) &&
Objects.equals(getTenantId(), that.getTenantId()) &&
Objects.equals(getTenantName(), that.getTenantName()) &&
Objects.equals(getRegionId(), that.getRegionId()) &&
Objects.equals(getRegionName(), that.getRegionName()) &&
Objects.equals(getServiceType(), that.getServiceType()) &&
Objects.equals(getSubscriberName(), that.getSubscriberName()) &&
Objects.equals(getServiceInstanceId(), that.getServiceInstanceId()) &&
Objects.equals(getServiceInstanceName(), that.getServiceInstanceName()) &&
Objects.equals(getServiceModelId(), that.getServiceModelId()) &&
Objects.equals(getServiceModelName(), that.getServiceModelName()) &&
Objects.equals(getServiceModelVersion(), that.getServiceModelVersion()) &&
Objects.equals(getCreatedBulkDate(), that.getCreatedBulkDate());
}
@Override
public int hashCode() {
return Objects.hash(getJobId(), getTemplateId(), getUserId(), getJobStatus(), getStatusModifiedDate(),
isHidden(), isPause(), getDeletedAt(), getOwningEntityId(), getOwningEntityName(), getProject(),
getAicZoneId(), getAicZoneName(), getTenantId(), getTenantName(), getRegionId(),
getRegionName(), getServiceType(), getSubscriberName(), getServiceInstanceId(),
getServiceInstanceName(), getServiceModelId(), getServiceModelName(),
getServiceModelVersion(), getCreatedBulkDate());
}
}
|