Replaced all tabs with spaces in java and pom.xml
[so.git] / bpmn / MSOCommonBPMN / src / main / java / org / onap / so / bpmn / servicedecomposition / bbobjects / CloudRegion.java
1 /*-
2  * ============LICENSE_START=======================================================
3  * ONAP - SO
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.onap.so.bpmn.servicedecomposition.bbobjects;
22
23 import java.io.Serializable;
24 import javax.persistence.Id;
25 import com.fasterxml.jackson.annotation.JsonProperty;
26 import org.apache.commons.lang3.builder.EqualsBuilder;
27 import org.apache.commons.lang3.builder.HashCodeBuilder;
28 import org.onap.so.bpmn.servicedecomposition.ShallowCopy;
29
30 public class CloudRegion implements Serializable, ShallowCopy<CloudRegion> {
31
32     private static final long serialVersionUID = 680593168655326021L;
33
34     @Id
35     @JsonProperty("lcp-cloud-region-id")
36     private String lcpCloudRegionId;
37     @Id
38     @JsonProperty("cloud-owner")
39     private String cloudOwner;
40     @JsonProperty("tenant-id")
41     private String tenantId;
42     @JsonProperty("complex")
43     private String complex;
44     @JsonProperty("cloud-region-version")
45     private String cloudRegionVersion;
46     @JsonProperty("orchestration-disabled")
47     private Boolean orchestrationDisabled;
48
49     public String getLcpCloudRegionId() {
50         return lcpCloudRegionId;
51     }
52
53     public void setLcpCloudRegionId(String lcpCloudRegionId) {
54         this.lcpCloudRegionId = lcpCloudRegionId;
55     }
56
57     public String getTenantId() {
58         return tenantId;
59     }
60
61     public void setTenantId(String tenantId) {
62         this.tenantId = tenantId;
63     }
64
65     public String getCloudOwner() {
66         return cloudOwner;
67     }
68
69     public void setCloudOwner(String cloudOwner) {
70         this.cloudOwner = cloudOwner;
71     }
72
73     /**
74      * i.e. aic version
75      */
76     public String getCloudRegionVersion() {
77         return cloudRegionVersion;
78     }
79
80     /**
81      * i.e. aic version
82      */
83     public void setCloudRegionVersion(String cloudRegionVersion) {
84         this.cloudRegionVersion = cloudRegionVersion;
85     }
86
87     /**
88      * i.e. aic clli, physical location id, site id
89      */
90     public String getComplex() {
91         return complex;
92     }
93
94     /**
95      * i.e. aic clli, physical location id, site id
96      */
97     public void setComplex(String complex) {
98         this.complex = complex;
99     }
100
101     public Boolean getOrchestrationDisabled() {
102         return orchestrationDisabled;
103     }
104
105     public void setOrchestrationDisabled(Boolean orchestrationDisabled) {
106         this.orchestrationDisabled = orchestrationDisabled;
107     }
108
109     @Override
110     public boolean equals(final Object other) {
111         if (!(other instanceof CloudRegion)) {
112             return false;
113         }
114         CloudRegion castOther = (CloudRegion) other;
115         return new EqualsBuilder().append(lcpCloudRegionId, castOther.lcpCloudRegionId)
116                 .append(cloudOwner, castOther.cloudOwner).isEquals();
117     }
118
119     @Override
120     public int hashCode() {
121         return new HashCodeBuilder().append(lcpCloudRegionId).append(cloudOwner).toHashCode();
122     }
123 }