6f24e60514315b2ba3c9c2820016f1eeb496669d
[so.git] /
1 /*-
2  * ============LICENSE_START=======================================================
3  * ONAP - SO
4  * ================================================================================
5  * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
6  *
7  * Modifications Copyright (C) 2019 IBM.
8  * ================================================================================
9  * Licensed under the Apache License, Version 2.0 (the "License");
10  * you may not use this file except in compliance with the License.
11  * You may obtain a copy of the License at
12  * 
13  *      http://www.apache.org/licenses/LICENSE-2.0
14  * 
15  * Unless required by applicable law or agreed to in writing, software
16  * distributed under the License is distributed on an "AS IS" BASIS,
17  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18  * See the License for the specific language governing permissions and
19  * limitations under the License.
20  * ============LICENSE_END=========================================================
21  */
22
23 package org.onap.so.adapters.vnfrest;
24
25 import java.util.HashMap;
26 import java.util.Map;
27 import javax.xml.bind.annotation.XmlAccessType;
28 import javax.xml.bind.annotation.XmlAccessorType;
29 import javax.xml.bind.annotation.XmlRootElement;
30 import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
31 import org.onap.so.entity.MsoRequest;
32 import org.onap.so.openstack.mappers.MapAdapter;
33 import com.fasterxml.jackson.annotation.JsonRootName;
34
35 /*
36  * README Map<String, String> elements when marshalled to XML produce a list of
37  * <entry><key>${MsoUtils.xmlEscape(key)}</key><value>${MsoUtils.xmlEscape(value)}</value></entry> elements. When
38  * marshalling to JSON they create a list of "${key}" : "${value}" pairs with no extra wrappers.
39  */
40 @JsonRootName("createVfModuleRequest")
41 @XmlRootElement(name = "createVfModuleRequest")
42 @XmlAccessorType(XmlAccessType.FIELD)
43 public class CreateVfModuleRequest extends VfRequestCommon {
44     private String cloudSiteId;
45     private String cloudOwner;
46     private String tenantId;
47
48     private String vnfId;
49     private String vnfType;
50     private String vnfVersion;
51
52     private String vfModuleId;
53     private String vfModuleName;
54     private String vfModuleType;
55
56     private String volumeGroupId;
57     private String volumeGroupStackId;
58     private String baseVfModuleId;
59     private String baseVfModuleStackId;
60     private String modelCustomizationUuid;
61
62     private String requestType;
63     private Boolean failIfExists = false;
64     private Boolean backout = true;
65     private Boolean enableBridge;
66     @XmlJavaTypeAdapter(MapAdapter.class)
67     private Map<String, Object> vfModuleParams = new HashMap<>();
68     private MsoRequest msoRequest = new MsoRequest();
69
70     public String getCloudSiteId() {
71         return cloudSiteId;
72     }
73
74     public void setCloudSiteId(String cloudSiteId) {
75         this.cloudSiteId = cloudSiteId;
76     }
77
78     public String getCloudOwner() {
79         return cloudOwner;
80     }
81
82     public void setCloudOwner(String cloudOwner) {
83         this.cloudOwner = cloudOwner;
84     }
85
86     public String getTenantId() {
87         return tenantId;
88     }
89
90     public void setTenantId(String tenantId) {
91         this.tenantId = tenantId;
92     }
93
94     public String getVnfId() {
95         return vnfId;
96     }
97
98     public void setVnfId(String vnfId) {
99         this.vnfId = vnfId;
100     }
101
102     public String getVfModuleName() {
103         return vfModuleName;
104     }
105
106     public void setVfModuleName(String vfModuleName) {
107         this.vfModuleName = vfModuleName;
108     }
109
110     public String getVnfType() {
111         return vnfType;
112     }
113
114     public void setVnfType(String vnfType) {
115         this.vnfType = vnfType;
116     }
117
118     public String getVnfVersion() {
119         return vnfVersion;
120     }
121
122     public void setVnfVersion(String vnfVersion) {
123         this.vnfVersion = vnfVersion;
124     }
125
126     public String getVfModuleId() {
127         return vfModuleId;
128     }
129
130     public void setVfModuleId(String vfModuleId) {
131         this.vfModuleId = vfModuleId;
132     }
133
134     public String getVfModuleType() {
135         return vfModuleType;
136     }
137
138     public void setVfModuleType(String vfModuleType) {
139         this.vfModuleType = vfModuleType;
140     }
141
142     public String getVolumeGroupId() {
143         return volumeGroupId;
144     }
145
146     public void setVolumeGroupId(String volumeGroupId) {
147         this.volumeGroupId = volumeGroupId;
148     }
149
150     public String getVolumeGroupStackId() {
151         return volumeGroupStackId;
152     }
153
154     public void setVolumeGroupStackId(String volumeGroupStackId) {
155         this.volumeGroupStackId = volumeGroupStackId;
156     }
157
158     public String getBaseVfModuleId() {
159         return baseVfModuleId;
160     }
161
162     public void setBaseVfModuleId(String baseVfModuleId) {
163         this.baseVfModuleId = baseVfModuleId;
164     }
165
166     public String getBaseVfModuleStackId() {
167         return baseVfModuleStackId;
168     }
169
170     public void setBaseVfModuleStackId(String baseVfModuleStackId) {
171         this.baseVfModuleStackId = baseVfModuleStackId;
172     }
173
174     public String getModelCustomizationUuid() {
175         return this.modelCustomizationUuid;
176     }
177
178     public void setModelCustomizationUuid(String modelCustomizationUuid) {
179         this.modelCustomizationUuid = modelCustomizationUuid;
180     }
181
182     public String getRequestType() {
183         return requestType;
184     }
185
186     public void setRequestType(String requestType) {
187         this.requestType = requestType;
188     }
189
190     public Boolean getFailIfExists() {
191         return failIfExists;
192     }
193
194     public void setFailIfExists(Boolean failIfExists) {
195         this.failIfExists = failIfExists;
196     }
197
198     public Boolean getBackout() {
199         return backout;
200     }
201
202     public void setBackout(Boolean backout) {
203         this.backout = backout;
204     }
205
206     public Map<String, Object> getVfModuleParams() {
207         return vfModuleParams;
208     }
209
210     public void setVfModuleParams(Map<String, Object> vfModuleParams) {
211         this.vfModuleParams = vfModuleParams;
212     }
213
214     public MsoRequest getMsoRequest() {
215         return msoRequest;
216     }
217
218     public void setMsoRequest(MsoRequest msoRequest) {
219         this.msoRequest = msoRequest;
220     }
221
222     public Boolean getEnableBridge() {
223         return this.enableBridge;
224     }
225
226     public void setEnableBridge(Boolean enableBridge) {
227         this.enableBridge = enableBridge;
228     }
229 }