1 /*******************************************************************************
2 * Copyright (c) 2017 Politecnico di Torino and others.
4 * All rights reserved. This program and the accompanying materials
5 * are made available under the terms of the Apache License, Version 2.0
6 * which accompanies this distribution, and is available at
7 * http://www.apache.org/licenses/LICENSE-2.0
8 *******************************************************************************/
10 package it.polito.escape.verify.model;
12 import javax.xml.bind.annotation.XmlRootElement;
14 import io.swagger.annotations.ApiModel;
15 import io.swagger.annotations.ApiModelProperty;
17 @ApiModel(value = "Error")
19 public class ErrorMessage {
21 @ApiModelProperty(example = "Error message")
22 private String errorMessage;
23 @ApiModelProperty(allowableValues = "400,403,404,500", value = "HTTP error code", example = "[400,403,404,500]")
24 private int errorCode;
25 @ApiModelProperty(example = "http://localhost:8080/verify/api-docs/")
26 private String documentation;
28 public ErrorMessage() {
32 public ErrorMessage(String errorMessage, int errorCode, String documentation) {
33 this.errorMessage = errorMessage;
34 this.errorCode = errorCode;
35 this.documentation = documentation;
38 public String getErrorMessage() {
42 public void setErrorMessage(String errorMessage) {
43 this.errorMessage = errorMessage;
46 public int getErrorCode() {
50 public void setErrorCode(int errorCode) {
51 this.errorCode = errorCode;
54 public String getDocumentation() {
58 public void setDocumentation(String documentation) {
59 this.documentation = documentation;