bda222159e2f32f8af51403fbf409d051098b91f
[so.git] / adapters / mso-adapters-rest-interface / src / main / java / org / openecomp / mso / adapters / vnfrest / VolumeGroupRollback.java
1 /*-
2  * ============LICENSE_START=======================================================
3  * OPENECOMP - MSO
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
21 package org.openecomp.mso.adapters.vnfrest;
22
23
24 import javax.xml.bind.annotation.XmlRootElement;
25
26 import org.codehaus.jackson.map.annotate.JsonRootName;
27 import org.jboss.resteasy.annotations.providers.NoJackson;
28
29 import org.openecomp.mso.entity.MsoRequest;
30
31 @JsonRootName("VolumeGroupRollback")
32 @XmlRootElement(name = "VolumeGroupRollback")
33 @NoJackson
34 public class VolumeGroupRollback {
35 //      “volumeGroupRollback”: {
36 //      “volumeGroupId”: “<A&AI_ VOLUME_GROUP_ID>”,
37 //      “volumeGroupStackId”: “<VOLUME_GROUP _STACK_ID>”,
38 //       “tenantId”: “<TENANT_ID>”,
39 //      “cloudSiteId”: “<CLOUD_CLLI>”,
40 //      “volumeGroupCreated”: TRUE|FALSE,
41 //      “msoRequest”: {
42 //              “requestId”: “<REQUEST_ID>”,
43 //              “serviceInstanceId”: “<SERVICE_INSTANCE_ID>”
44 //      }
45 //},
46
47         private String volumeGroupId;
48         private String volumeGroupStackId;
49         private String tenantId;
50         private String cloudSiteId;
51         private boolean volumeGroupCreated = false;
52         private MsoRequest msoRequest;
53         private String messageId;
54
55         public VolumeGroupRollback() {
56         }
57
58         public VolumeGroupRollback(VolumeGroupRollback vrb, String volumeGroupStackId, String messageId)
59         {
60                 this.volumeGroupId      = vrb.getVolumeGroupId();
61                 this.volumeGroupStackId = volumeGroupStackId;
62                 this.tenantId           = vrb.getTenantId();
63                 this.cloudSiteId        = vrb.getCloudSiteId();
64                 this.volumeGroupCreated = vrb.isVolumeGroupCreated();
65                 this.msoRequest         = vrb.getMsoRequest();
66                 this.messageId          = messageId;
67         }
68
69         public VolumeGroupRollback(
70                         String volumeGroupId,
71                         String volumeGroupStackId,
72                         boolean volumeGroupCreated,
73                         String tenantId,
74                         String cloudSiteId,
75                         MsoRequest msoRequest,
76                         String messageId)
77         {
78                 super();
79                 this.volumeGroupId = volumeGroupId;
80                 this.volumeGroupStackId = volumeGroupStackId;
81                 this.volumeGroupCreated = volumeGroupCreated;
82                 this.tenantId = tenantId;
83                 this.cloudSiteId = cloudSiteId;
84                 this.msoRequest = msoRequest;
85                 this.messageId = messageId;
86         }
87
88         public String getVolumeGroupId() {
89                 return volumeGroupId;
90         }
91         public void setVolumeGroupId(String volumeGroupId) {
92                 this.volumeGroupId = volumeGroupId;
93         }
94         public String getVolumeGroupStackId() {
95                 return volumeGroupStackId;
96         }
97         public void setVolumeGroupStackId(String volumeGroupStackId) {
98                 this.volumeGroupStackId = volumeGroupStackId;
99         }
100         public String getTenantId() {
101                 return tenantId;
102         }
103         public void setTenantId(String tenantId) {
104                 this.tenantId = tenantId;
105         }
106         public String getCloudSiteId() {
107                 return cloudSiteId;
108         }
109         public void setCloudSiteId(String cloudSiteId) {
110                 this.cloudSiteId = cloudSiteId;
111         }
112         public boolean isVolumeGroupCreated() {
113                 return volumeGroupCreated;
114         }
115         public void setVolumeGroupCreated(boolean volumeGroupCreated) {
116                 this.volumeGroupCreated = volumeGroupCreated;
117         }
118         public MsoRequest getMsoRequest() {
119                 return msoRequest;
120         }
121         public void setMsoRequest(MsoRequest msoRequest) {
122                 this.msoRequest = msoRequest;
123         }
124         public String getMessageId() {
125                 return messageId;
126         }
127         public void setMessageId(String messageId) {
128                 this.messageId = messageId;
129         }
130 }