001/*
002 * (C) Copyright 2014 Nuxeo SA (http://nuxeo.com/) and others.
003 *
004 * Licensed under the Apache License, Version 2.0 (the "License");
005 * you may not use this file except in compliance with the License.
006 * You may obtain a copy of the License at
007 *
008 *     http://www.apache.org/licenses/LICENSE-2.0
009 *
010 * Unless required by applicable law or agreed to in writing, software
011 * distributed under the License is distributed on an "AS IS" BASIS,
012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
013 * See the License for the specific language governing permissions and
014 * limitations under the License.
015 *
016 * Contributors:
017 *     vpasquier <vpasquier@nuxeo.com>
018 */
019package org.nuxeo.box.api.marshalling.exceptions;
020
021import com.fasterxml.jackson.annotation.JsonProperty;
022
023/**
024 * Nuxeo Box Exception
025 *
026 * @since 5.9.3
027 */
028public class NXBoxJsonException {
029
030    protected String type = "error";
031
032    protected String code;
033
034    protected int status;
035
036    protected String helpUrl = null;
037
038    protected String message;
039
040    protected String request_id = null;
041
042    @JsonProperty("type")
043    public String getType() {
044        return this.type;
045    }
046
047    @JsonProperty("type")
048    public void setType(String type) {
049        this.type = type;
050    }
051
052    @JsonProperty("code")
053    public String getCode() {
054        return code;
055    }
056
057    @JsonProperty("code")
058    public void setCode(String code) {
059        this.code = code;
060    }
061
062    @JsonProperty("status")
063    public int getStatus() {
064        return status;
065    }
066
067    @JsonProperty("status")
068    public void setStatus(int status) {
069        this.status = status;
070    }
071
072    @JsonProperty("help_url")
073    public String getHelpUrl() {
074        return helpUrl;
075    }
076
077    @JsonProperty("help_url")
078    public void setHelpUrl(String helpUrl) {
079        this.helpUrl = helpUrl;
080    }
081
082    @JsonProperty("message")
083    public String getMessage() {
084        return message;
085    }
086
087    @JsonProperty("message")
088    public void setMessage(String message) {
089        this.message = message;
090    }
091
092    @JsonProperty("request_id")
093    public String getRequest_id() {
094        return request_id;
095    }
096
097    @JsonProperty("request_id")
098    public void setRequest_id(String request_id) {
099        this.request_id = request_id;
100    }
101}