Replaced all tabs with spaces in java and pom.xml
[so.git] / bpmn / MSOCommonBPMN / src / main / java / org / onap / so / bpmn / servicedecomposition / bbobjects / VolumeGroup.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 java.util.HashMap;
25 import java.util.Map;
26 import javax.persistence.Id;
27 import org.apache.commons.lang3.builder.EqualsBuilder;
28 import org.apache.commons.lang3.builder.HashCodeBuilder;
29 import org.onap.so.bpmn.servicedecomposition.modelinfo.ModelInfoVfModule;
30 import org.onap.so.db.catalog.beans.OrchestrationStatus;
31 import com.fasterxml.jackson.annotation.JsonProperty;
32 import com.fasterxml.jackson.annotation.JsonRootName;
33 import org.onap.so.bpmn.servicedecomposition.ShallowCopy;
34
35 @JsonRootName("volume-group")
36 public class VolumeGroup implements Serializable, ShallowCopy<VolumeGroup> {
37
38     private static final long serialVersionUID = 870124265764370922L;
39
40     @Id
41     @JsonProperty("volume-group-id")
42     private String volumeGroupId;
43     @JsonProperty("volume-group-name")
44     private String volumeGroupName;
45     @JsonProperty("vnf-type")
46     private String vnfType;
47     @JsonProperty("orchestration-status")
48     private OrchestrationStatus orchestrationStatus;
49     @JsonProperty("cloud-params")
50     private Map<String, String> cloudParams = new HashMap<>();
51     @JsonProperty("cascaded")
52     private Boolean cascaded;
53     @JsonProperty("heat-stack-id")
54     private String heatStackId;
55     @JsonProperty("model-info-vf-module")
56     private ModelInfoVfModule modelInfoVfModule;
57
58     public ModelInfoVfModule getModelInfoVfModule() {
59         return modelInfoVfModule;
60     }
61
62     public void setModelInfoVfModule(ModelInfoVfModule modelInfoVfModule) {
63         this.modelInfoVfModule = modelInfoVfModule;
64     }
65
66     public String getHeatStackId() {
67         return heatStackId;
68     }
69
70     public void setHeatStackId(String heatStackId) {
71         this.heatStackId = heatStackId;
72     }
73
74     public String getVolumeGroupId() {
75         return volumeGroupId;
76     }
77
78     public void setVolumeGroupId(String volumeGroupId) {
79         this.volumeGroupId = volumeGroupId;
80     }
81
82     public String getVolumeGroupName() {
83         return volumeGroupName;
84     }
85
86     public void setVolumeGroupName(String volumeGroupName) {
87         this.volumeGroupName = volumeGroupName;
88     }
89
90     public String getVnfType() {
91         return vnfType;
92     }
93
94     public void setVnfType(String vnfType) {
95         this.vnfType = vnfType;
96     }
97
98     public OrchestrationStatus getOrchestrationStatus() {
99         return orchestrationStatus;
100     }
101
102     public void setOrchestrationStatus(OrchestrationStatus orchestrationStatus) {
103         this.orchestrationStatus = orchestrationStatus;
104     }
105
106     public Map<String, String> getCloudParams() {
107         return cloudParams;
108     }
109
110     public void setCloudParams(Map<String, String> cloudParams) {
111         this.cloudParams = cloudParams;
112     }
113
114     public Boolean isCascaded() {
115         return cascaded;
116     }
117
118     public void setCascaded(boolean cascaded) {
119         this.cascaded = cascaded;
120     }
121
122     @Override
123     public boolean equals(final Object other) {
124         if (!(other instanceof VolumeGroup)) {
125             return false;
126         }
127         VolumeGroup castOther = (VolumeGroup) other;
128         return new EqualsBuilder().append(volumeGroupId, castOther.volumeGroupId).isEquals();
129     }
130
131     @Override
132     public int hashCode() {
133         return new HashCodeBuilder().append(volumeGroupId).toHashCode();
134     }
135 }