b8f61bd8847bddc3228f5ff7bd703c73031bb47c
[ccsdk/apps.git] / ms / vlantag-api / src / main / java / org / onap / ccsdk / apps / ms / vlantagapi / core / model / AssignVlanTagResponseOutput.java
1 /*******************************************************************************\r
2  * Copyright © 2017-2018 AT&T Intellectual Property.\r
3  * \r
4  * Licensed under the Apache License, Version 2.0 (the "License");\r
5  * you may not use this file except in compliance with the License.\r
6  * You may obtain a copy of the License at\r
7  * \r
8  *     http://www.apache.org/licenses/LICENSE-2.0\r
9  * \r
10  * Unless required by applicable law or agreed to in writing, software\r
11  * distributed under the License is distributed on an "AS IS" BASIS,\r
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
13  * See the License for the specific language governing permissions and\r
14  * limitations under the License.\r
15  ******************************************************************************/\r
16 package org.onap.ccsdk.apps.ms.vlantagapi.core.model;\r
17 \r
18 import java.util.ArrayList;\r
19 import java.util.List;\r
20 import java.util.Objects;\r
21 \r
22 import javax.validation.Valid;\r
23 \r
24 import com.fasterxml.jackson.annotation.JsonProperty;\r
25 \r
26 import io.swagger.annotations.ApiModelProperty;\r
27 \r
28 /**\r
29  * AssignVlanTagResponseOutput.java Purpose: Provide Assign VlanTag Response Output Model\r
30  *\r
31  * @author Saurav Paira\r
32  * @version 1.0\r
33  */\r
34 public class AssignVlanTagResponseOutput {\r
35 \r
36         private @Valid String resourceName = null;\r
37         private @Valid String resourceValue = null;\r
38         private @Valid String resourceVlanRole = null;\r
39         private @Valid List<VlanTag> storedElements = new ArrayList<>();\r
40 \r
41         /**\r
42          **/\r
43         public AssignVlanTagResponseOutput resourceName(String resourceName) {\r
44                 this.resourceName = resourceName;\r
45                 return this;\r
46         }\r
47 \r
48         @ApiModelProperty(value = "")\r
49         @JsonProperty("resource-name")\r
50         public String getResourceName() {\r
51                 return resourceName;\r
52         }\r
53 \r
54         public void setResourceName(String resourceName) {\r
55                 this.resourceName = resourceName;\r
56         }\r
57 \r
58         /**\r
59          **/\r
60         public AssignVlanTagResponseOutput resourceValue(String resourceValue) {\r
61                 this.resourceValue = resourceValue;\r
62                 return this;\r
63         }\r
64 \r
65         @ApiModelProperty(value = "")\r
66         @JsonProperty("resource-value")\r
67         public String getResourceValue() {\r
68                 return resourceValue;\r
69         }\r
70 \r
71         public void setResourceValue(String resourceValue) {\r
72                 this.resourceValue = resourceValue;\r
73         }\r
74 \r
75         /**\r
76          **/\r
77         public AssignVlanTagResponseOutput resourceVlanRole(String resourceVlanRole) {\r
78                 this.resourceVlanRole = resourceVlanRole;\r
79                 return this;\r
80         }\r
81 \r
82         @ApiModelProperty(value = "")\r
83         @JsonProperty("resource-vlan-role")\r
84         public String getResourceVlanRole() {\r
85                 return resourceVlanRole;\r
86         }\r
87 \r
88         public void setResourceVlanRole(String resourceVlanRole) {\r
89                 this.resourceVlanRole = resourceVlanRole;\r
90         }\r
91 \r
92         /**\r
93          **/\r
94         public AssignVlanTagResponseOutput storedElements(List<VlanTag> storedElements) {\r
95                 this.storedElements = storedElements;\r
96                 return this;\r
97         }\r
98 \r
99         @ApiModelProperty(value = "")\r
100         @JsonProperty("stored-elements")\r
101         public List<VlanTag> getStoredElements() {\r
102                 return storedElements;\r
103         }\r
104 \r
105         public void setStoredElements(List<VlanTag> storedElements) {\r
106                 this.storedElements = storedElements;\r
107         }\r
108 \r
109         @Override\r
110         public boolean equals(java.lang.Object o) {\r
111                 if (this == o) {\r
112                         return true;\r
113                 }\r
114                 if (o == null || getClass() != o.getClass()) {\r
115                         return false;\r
116                 }\r
117                 AssignVlanTagResponseOutput assignVlanTagResponseOutput = (AssignVlanTagResponseOutput) o;\r
118                 return Objects.equals(resourceName, assignVlanTagResponseOutput.resourceName)\r
119                                 && Objects.equals(resourceValue, assignVlanTagResponseOutput.resourceValue)\r
120                                 && Objects.equals(resourceVlanRole, assignVlanTagResponseOutput.resourceVlanRole)\r
121                                 && Objects.equals(storedElements, assignVlanTagResponseOutput.storedElements);\r
122         }\r
123 \r
124         @Override\r
125         public int hashCode() {\r
126                 return Objects.hash(resourceName, resourceValue, resourceVlanRole, storedElements);\r
127         }\r
128 \r
129         @Override\r
130         public String toString() {\r
131                 StringBuilder sb = new StringBuilder();\r
132                 sb.append("class AssignVlanTagResponseOutput {\n");\r
133 \r
134                 sb.append("    resourceName: ").append(toIndentedString(resourceName)).append("\n");\r
135                 sb.append("    resourceValue: ").append(toIndentedString(resourceValue)).append("\n");\r
136                 sb.append("    resourceVlanRole: ").append(toIndentedString(resourceVlanRole)).append("\n");\r
137                 sb.append("    storedElements: ").append(toIndentedString(storedElements)).append("\n");\r
138                 sb.append("}");\r
139                 return sb.toString();\r
140         }\r
141 \r
142         /**\r
143          * Convert the given object to string with each line indented by 4 spaces\r
144          * (except the first line).\r
145          */\r
146         private String toIndentedString(java.lang.Object o) {\r
147                 if (o == null) {\r
148                         return "null";\r
149                 }\r
150                 return o.toString().replace("\n", "\n    ");\r
151         }\r
152 \r
153 }\r