import { AbstractSession , TextUtils , ImperativeExpect } from "@zowe/imperative" ; import { noSessionProvisioning } from "./ProvisioningConstants" ; export class export class ProvisioningValidator { static param { AbstractSession } session memberof public static validateSession ( session ) { ImperativeExpect . toNotBeNullOrUndefined ( session , TextUtils . formatMessage ( noSessionProvisioning . message ) ) ; } static param { string } text param { string } errorMsg memberof public static validateString ( text , errorMsg ) { ImperativeExpect . toNotBeNullOrUndefined ( text , errorMsg ) ; } static param { string } text param { string } errorMsg memberof public static validateNotEmptyString ( text , errorMsg ) { ImperativeExpect . toNotBeEqual ( "" , text , errorMsg ) ; ProvisioningValidator . validateString ( text , errorMsg ) ; } }