2 * ============LICENSE_START=======================================================
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
11 * http://www.apache.org/licenses/LICENSE-2.0
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=========================================================
21 package org.openecomp.mso.openstack.beans;
24 import java.util.List;
26 import org.openecomp.mso.entity.MsoRequest;
29 * Javabean representing the rollback criteria following a "Create Network"
30 * or "Update Network" operation. This structure can be passed back to the
31 * "Rollback Network" operation to undo the effects of the create/update.
33 * Once a network is created, the only possible update through MSO is to
34 * the set of VLANs supported by the network. The vlans attribute of the
35 * rollback object contains the previous VLANs before update.
39 public class NetworkRollback {
40 private String networkId;
41 private String neutronNetworkId;
42 private String networkStackId;
43 private String tenantId;
44 private String cloudId;
45 private String networkType;
46 private String modelCustomizationUuid;
47 private boolean networkCreated = false;
48 // Previous values for updates
49 private String networkName = null;
50 private String physicalNetwork = null;
51 private List<Integer> vlans = null;
52 private MsoRequest msoRequest;
54 public String getNetworkId() {
57 public void setNetworkId(String networkId) {
58 this.networkId = networkId;
61 public String getNeutronNetworkId() {
62 return neutronNetworkId;
64 public void setNeutronNetworkId(String neutronNetworkId) {
65 this.neutronNetworkId = neutronNetworkId;
68 public String getNetworkStackId() {
69 return networkStackId;
71 public void setNetworkStackId(String networkStackId) {
72 this.networkStackId = networkStackId;
74 public String getTenantId() {
77 public void setTenantId(String tenantId) {
78 this.tenantId = tenantId;
81 public String getCloudId() {
84 public void setCloudId(String cloudId) {
85 this.cloudId = cloudId;
88 public String getNetworkType() {
91 public void setNetworkType(String networkType) {
92 this.networkType = networkType;
95 public String getModelCustomizationUuid() {
96 return this.modelCustomizationUuid;
99 public void setModelCustomizationUuid(String modelCustomizationUuid) {
100 this.modelCustomizationUuid = modelCustomizationUuid;
103 public boolean getNetworkCreated() {
104 return networkCreated;
106 public void setNetworkCreated(boolean networkCreated) {
107 this.networkCreated = networkCreated;
110 public String getNetworkName() {
113 public void setNetworkName(String networkName) {
114 this.networkName = networkName;
117 public String getPhysicalNetwork() {
118 return physicalNetwork;
120 public void setPhysicalNetwork(String physicalNetwork) {
121 this.physicalNetwork = physicalNetwork;
124 public List<Integer> getVlans () {
127 public void setVlans (List<Integer> vlans) {
131 public MsoRequest getMsoRequest() {
134 public void setMsoRequest (MsoRequest msoRequest) {
135 this.msoRequest = msoRequest;
139 public String toString() {
140 return "NetworkRollback [networkId=" + networkId
141 + ", neutronNetworkId=" + neutronNetworkId + ", networkStackId="
142 + networkStackId + ", tenantId=" + tenantId + ", cloudId="
143 + cloudId + ", networkType=" + networkType
144 + ", networkCreated=" + networkCreated + ", networkName=" + networkName
145 + ", physicalNetwork=" + physicalNetwork + "]";