tapbundle/ts/tapbundle.classes.tapwrap.ts

25 lines
407 B
TypeScript
Raw Permalink Normal View History

import * as plugins from './tapbundle.plugins';
2017-07-05 15:57:28 +00:00
export interface ITapWrapFunction {
(): Promise<any>;
2017-07-05 15:57:28 +00:00
}
export class TapWrap {
wrapFunction: ITapWrapFunction;
2017-07-05 22:06:18 +00:00
/**
* the constructor
*/
constructor(wrapFunctionArg: ITapWrapFunction) {
2017-07-05 15:57:28 +00:00
// nothing here
this.wrapFunction = wrapFunctionArg;
2017-07-05 22:06:18 +00:00
}
/**
* run the wrapFunction
*/
async run() {
await this.wrapFunction();
2017-07-05 15:57:28 +00:00
}
}