@zowe/cli
Version:
Zowe CLI is a command line interface (CLI) that provides a simple and streamlined way to interact with IBM z/OS.
32 lines • 1.54 kB
TypeScript
import { AbstractSession, ICommandHandler, IHandlerParameters } from "@zowe/imperative";
import { IZosFilesResponse } from "@zowe/zos-files-for-zowe-sdk";
/**
* This class is used by the various zosfiles handlers as the base class for their implementation.
* All handlers within zosfiles should extend this class.
*
* This class should not be used outside of the zosfiles package.
*
* @private
*/
export declare abstract class ZosFilesBaseHandler implements ICommandHandler {
/**
* This will grab the zosmf profile and create a session before calling the subclass
* {@link ZosFilesBaseHandler#processWithSession} method.
*
* @param {IHandlerParameters} commandParameters Command parameters sent by imperative.
*
* @returns {Promise<void>}
*/
process(commandParameters: IHandlerParameters): Promise<void>;
/**
* This is called by the {@link ZosFilesBaseHandler#process} after it creates a session. Should
* be used so that every class under files does not have to instantiate the session object.
*
* @param {IHandlerParameters} commandParameters Command parameters sent to the handler.
* @param {AbstractSession} session The session object generated from the zosmf profile.
*
* @returns {Promise<IZosFilesResponse>} The response from the underlying zos-files api call.
*/
abstract processWithSession(commandParameters: IHandlerParameters, session: AbstractSession): Promise<IZosFilesResponse>;
}
//# sourceMappingURL=ZosFilesBase.handler.d.ts.map