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

com.gocardless.errors.MalformedResponseException Maven / Gradle / Ivy

There is a newer version: 6.0.0
Show newest version
package com.gocardless.errors;

import com.gocardless.GoCardlessException;

/**
 * Exception thrown when a response is returned from the API which isn't valid JSON (for example, an
 * HTML error page returned from a load balancer)
 */
public class MalformedResponseException extends GoCardlessException {
    private final String responseBody;

    public MalformedResponseException(String responseBody) {
        super("Malformed response received from server");
        this.responseBody = responseBody;
    }

    public String getResponseBody() {
        return responseBody;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy