2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright (C) 2017 - 2019 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.onap.vid.mso.model;
23 import com.fasterxml.jackson.annotation.*;
24 import org.apache.commons.lang.builder.EqualsBuilder;
25 import org.apache.commons.lang.builder.HashCodeBuilder;
26 import org.apache.commons.lang.builder.ToStringBuilder;
28 import java.util.HashMap;
33 * fields communicating the cloud configuration in a standard way
36 @JsonInclude(JsonInclude.Include.NON_NULL)
43 public class CloudConfiguration {
46 * Location identifier for the node
49 @JsonProperty("nodeLocation")
50 private String nodeLocation;
52 * LCP Node Location identifier
55 @JsonProperty("lcpCloudRegionId")
56 private String lcpCloudRegionId;
61 @JsonProperty("tenantId")
62 private String tenantId;
67 @JsonProperty("cloudOwner")
68 private String cloudOwner;
70 private Map<String, Object> additionalProperties = new HashMap<>();
73 * Location identifier for the node
78 @JsonProperty("nodeLocation")
79 public String getNodeLocation() {
84 * Location identifier for the node
89 @JsonProperty("nodeLocation")
90 public void setNodeLocation(String nodeLocation) {
91 this.nodeLocation = nodeLocation;
95 * LCP Node Location identifier
98 * The lcpCloudRegionId
100 @JsonProperty("lcpCloudRegionId")
101 public String getLcpCloudRegionId() {
102 return lcpCloudRegionId;
106 * LCP Node Location identifier
108 * @param lcpCloudRegionId
109 * The lcpCloudRegionId
111 @JsonProperty("lcpCloudRegionId")
112 public void setLcpCloudRegionId(String lcpCloudRegionId) {
113 this.lcpCloudRegionId = lcpCloudRegionId;
117 * Openstack tenant id
122 @JsonProperty("tenantId")
123 public String getTenantId() {
128 * Openstack tenant id
133 @JsonProperty("tenantId")
134 public void setTenantId(String tenantId) {
135 this.tenantId = tenantId;
144 @JsonProperty("cloudOwner")
145 public String getCloudOwner() {
155 @JsonProperty("cloudOwner")
156 public void setCloudOwner(String cloudOwner) {
157 this.cloudOwner = cloudOwner;
161 public String toString() {
162 return ToStringBuilder.reflectionToString(this);
166 public Map<String, Object> getAdditionalProperties() {
167 return this.additionalProperties;
171 public void setAdditionalProperty(String name, Object value) {
172 this.additionalProperties.put(name, value);
176 public int hashCode() {
177 return new HashCodeBuilder().append(nodeLocation).append(lcpCloudRegionId).append(tenantId).append(cloudOwner).append(additionalProperties).toHashCode();
181 public boolean equals(Object other) {
185 if (!(other instanceof CloudConfiguration)) {
188 CloudConfiguration rhs = ((CloudConfiguration) other);
189 return new EqualsBuilder().append(nodeLocation, rhs.nodeLocation).append(lcpCloudRegionId, rhs.lcpCloudRegionId).append(tenantId, rhs.tenantId).append(cloudOwner, rhs.cloudOwner).append(additionalProperties, rhs.additionalProperties).isEquals();