All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.qiniu.common.SuitsException Maven / Gradle / Ivy

There is a newer version: 8.4.8
Show newest version
package com.qiniu.common;

import java.io.IOException;

public class SuitsException extends IOException {

    private int statusCode;

    public SuitsException(int statusCode, String error) {
        super("code: " + statusCode + ", error: " + error);
        this.statusCode = statusCode;
    }

    public SuitsException(Exception e, int statusCode) {
        super(statusCode + ", " + e.getMessage(), e);
        this.statusCode = statusCode;
    }

    public SuitsException(Exception e, int statusCode, String error) {
        super(statusCode + ", " + error + ", " + e.getMessage(), e);
        this.statusCode = statusCode;
    }

    public SuitsException(SuitsException e, String message) {
        super(e.getMessage() + ", " + message, e);
        this.statusCode = e.getStatusCode();
    }

    public int getStatusCode() {
        return statusCode;
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy