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