@zowe/core-for-zowe-sdk
Version:
Core libraries shared by Zowe SDK packages
53 lines • 2.17 kB
TypeScript
import { IImperativeError, Logger, RestClient, Queue, IQueueThrottleOptions } from "@zowe/imperative";
/**
* Wrapper for invoke z/OSMF API through the RestClient to perform common error
* handling and checking and resolve promises according to generic types
* @export
* @class ZosmfRestClient
* @extends {RestClient}
*/
export declare class ZosmfRestClient extends RestClient {
/**
* Implementation of a static request queue for all Zosmf Rest clients.
* Creates a request queue if one does not exist.
* @type {Queue}
* @memberof ZosmfRestClient
*/
private static mRequestQueue;
/**
* Create a request queue if one does not exist. Set the throttling options if provided and they do exist.
* @param { IQueueThrottleOptions } options - The throttling options to apply to the z/OSMF REST client
*/
private static verifyRequestQueue;
/**
* Reimplementation of the request queue getter to get the static request queue.
* @type {Queue}
* @memberof ZosmfRestClient
*/
protected get requestQueue(): Queue;
/**
* Set the throttling options on the z/OSMF REST client
* @param { IQueueThrottleOptions } options - the throttling options to apply to the z/OSMF REST client
*/
static setThrottlingOptions(options: IQueueThrottleOptions): void;
/**
* Use the Zowe logger instead of the imperative logger
* @type {Logger}
*/
get log(): Logger;
/**
* Append z/OSMF specific headers to the callers headers for cases
* where a header is common to every request.
* @param {any[] | undefined} headers - current header array
* @memberof ZosmfRestClient
*/
protected appendHeaders(headers: any[] | undefined): any[];
/**
* Process an error encountered in the rest client
* @param {IImperativeError} original - the original error automatically built by the abstract rest client
* @returns {IImperativeError} - the processed error with details added
* @memberof ZosmfRestClient
*/
protected processError(original: IImperativeError): IImperativeError;
}
//# sourceMappingURL=ZosmfRestClient.d.ts.map