Remove unused method
[portal/nonrtric-controlpanel.git] / webapp-backend / src / main / java / org / oransc / portal / nonrtric / controlpanel / model / PolicyInstance.java
1 /*-
2  * ========================LICENSE_START=================================
3  * O-RAN-SC
4  * %%
5  * Copyright (C) 2019 Nordix Foundation
6  * Modifications Copyright (C) 2020 Nordix Foundation
7  * %%
8  * Licensed under the Apache License, Version 2.0 (the "License");
9  * you may not use this file except in compliance with the License.
10  * You may obtain a copy of the License at
11  *
12  *      http://www.apache.org/licenses/LICENSE-2.0
13  *
14  * Unless required by applicable law or agreed to in writing, software
15  * distributed under the License is distributed on an "AS IS" BASIS,
16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17  * See the License for the specific language governing permissions and
18  * limitations under the License.
19  * ========================LICENSE_END===================================
20  */
21
22 package org.oransc.portal.nonrtric.controlpanel.model;
23
24 import com.google.gson.annotations.SerializedName;
25
26 import lombok.Builder;
27
28 import org.immutables.gson.Gson;
29
30 @Gson.TypeAdapters
31 @Builder
32 public class PolicyInstance {
33
34     @SerializedName(value = "policy_id")
35     public String policyId;
36
37     @SerializedName(value = "policytype_id")
38     public String policyTypeId;
39
40     @SerializedName(value = "ric_id")
41     public String ricId;
42
43     @SerializedName(value = "policy_data")
44     public Object policyData;
45
46     @SerializedName(value = "service_id")
47     public String serviceId;
48
49     @SerializedName(value = "transient")
50     public boolean isTransient = false;
51
52     @SerializedName(value = "status_notification_uri")
53     public String statusNotificationUri = "";
54
55     @SerializedName(value = "lastModified")
56     public String lastModified = "";
57
58     public boolean validate() {
59         return policyId != null && policyTypeId != null && ricId != null && policyData != null && serviceId != null;
60     }
61
62 }