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

org.hyperledger.fabric_ca.sdk.HFCACertificateResponse Maven / Gradle / Ivy

Go to download

Java SDK for Hyperledger Fabric. Deprecated as of Fabric v2.5, replaced by org.hyperledger.fabric:fabric-gateway.

There is a newer version: 2.2.26
Show newest version
package org.hyperledger.fabric_ca.sdk;

import java.util.Collection;

/**
 * The response from a certificate API request, contains the status code of the
 * request and certificates that were retrieved
 */
public class HFCACertificateResponse {
    private final int statusCode;
    private final Collection certs;

    /**
     * Contains the response from the server with status code and credentials requested
     *
     * @param statusCode Status code of the HTTP request
     * @param certs The certificates return from the GET request
     */
    HFCACertificateResponse(int statusCode, Collection certs) {
        this.statusCode = statusCode;
        this.certs = certs;
    }

    /**
     * Returns the status code of the request
     *
     * @return HTTP status code
     */
    public int getStatusCode() {
        return statusCode;
    }

    /**
     * Returns the certificates that were retrieved from the GET certificate request
     *
     * @return Certificates
     */
    public Collection getCerts() {
        return certs;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy