d829aae03400f818a5d6ba1f264f539c33874d9c
[externalapi/nbi.git] / src / main / java / org / onap / nbi / exceptions / ApiError.java
1 package org.onap.nbi.exceptions;
2
3 import javax.xml.bind.annotation.XmlAccessType;
4 import javax.xml.bind.annotation.XmlAccessorType;
5 import javax.xml.bind.annotation.XmlElement;
6 import javax.xml.bind.annotation.XmlType;
7
8 @XmlAccessorType(XmlAccessType.FIELD)
9 @XmlType(name = "Error", propOrder = {"code", "message", "description", "infoURL"})
10 public class ApiError {
11     @XmlElement(required = true)
12     protected String code;
13     @XmlElement(required = true)
14     protected String message;
15     @XmlElement(required = true)
16     private String description;
17     @XmlElement(required = true)
18     protected String infoURL;
19
20     public ApiError() {}
21
22     public ApiError(String code, String message, String description, String infoURL) {
23         this.code = code;
24         this.message = message;
25         this.description = description;
26         this.infoURL = infoURL;
27     }
28
29     public String getCode() {
30         return code;
31     }
32
33     public void setCode(String code) {
34         this.code = code;
35     }
36
37     public String getMessage() {
38         return message;
39     }
40
41     public void setMessage(String message) {
42         this.message = message;
43     }
44
45     public String getDescription() {
46         return description;
47     }
48
49     public void setDescription(String description) {
50         this.description = description;
51     }
52
53     public String getInfoURL() {
54         return infoURL;
55     }
56
57     public void setInfoURL(String infoURL) {
58         this.infoURL = infoURL;
59     }
60 }
61