@decaf-ts/fabric-weaver
Version:
template for ts projects
40 lines (39 loc) • 1.81 kB
TypeScript
import { Logger } from "@decaf-ts/logging";
import { FabricCAClientCommand } from "../constants/fabric-ca-client";
import { CommadCSRConfig, EnrollmentConfig, IdentityConfig, RevokeConfig, TLSConfig } from "../interfaces/fabric/fabric-ca-client-config";
import { FabricCAServerCurveName } from "../constants/fabric-ca-server";
import { FabricLogLevel } from "../constants/fabric-general";
export declare class FabricCAClientCommandBuilder {
private log;
private binName;
private command;
private args;
constructor(logger?: Logger);
/**
* @description Sets the command for the Fabric CA Server.
* @summary Configures the primary action for the Fabric CA Server, such as starting the server or generating certificates.
* @param {FabricCAServerCommand} [command] - The command to be executed by the Fabric CA Server.
* @return {this} The current instance of the builder for method chaining.
*/
setCommand(command?: FabricCAClientCommand): this;
setCSR(csr?: CommadCSRConfig): this;
setHelp(show?: boolean): this;
setHome(home?: string): this;
setCAName(name?: string): this;
setUrl(url?: string): this;
setEnrollment(enrollment?: EnrollmentConfig): this;
setIdentity(identity?: IdentityConfig): this;
setIdemixCurve(curve?: FabricCAServerCurveName): this;
setLogLevel(level: FabricLogLevel): this;
setMspdir(mspdir?: string): this;
setMyHost(myHost?: string): this;
setRevoke(revocation?: RevokeConfig): this;
setTLS(tls?: TLSConfig): this;
copyKey(pathToMSPDir?: string, destinationDir?: string): this;
changeKeyName(pathToMSPDir?: string, changeKeyName?: boolean): this;
build(): string;
getCommand(): string;
getBinary(): string;
getArgs(): string[];
execute(): Promise<void>;
}