0.0.1 • Published 11 months ago

tasks-mad-queue v0.0.1

Weekly downloads
-
License
MIT
Repository
github
Last release
11 months ago

Tasks Mad Queue

npm version

  // API

public start(): void {
    this.influxProcess();
}

public enqueue(func: TasksQueueFuncType): void {
    this.validations();
    this.enqueueInnerInflux(func);
}

public enqueueAndWait<T>(func: TasksQueueFuncType<T>): Promise<T> {
    this.validations();
    return this.enqueueInnerAndWait<T>(func);
}

public getConfig(): ITasksQueueConfig {
    return this.config;
}

public async wait(): Promise<void> {
    await this.currentProcess;
    return;
}

public isRunning(): boolean {
    return this.isActive;
}