Skip to content

Commit

Permalink
docs: add JSDoc to StateHandler
Browse files Browse the repository at this point in the history
  • Loading branch information
OsirisAnubiz committed Oct 10, 2024
1 parent 537ec28 commit c7d4614
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions packages/nestjs-batch-queue/src/batch-queue/state-handler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,16 @@ import type { OnChangeStateToFailCallback } from './types/index.js'
export class StateHandler {
constructor(private batchQueue: BatchQueue<any>) {}

/**
* Delegates to {@link BatchQueue.onChangeTotalStateToOk}
*/
public onChangeTotalStateToOk(callback: OnChangeStateToOkCallback): void {
this.batchQueue.onChangeTotalStateToOk(callback)
}

/**
* Delegates to {@link BatchQueue.onChangeTotalStateToFail}
*/
public onChangeTotalStateToFail(callback: OnChangeStateToFailCallback): void {
this.batchQueue.onChangeTotalStateToFail(callback)
}
Expand Down

0 comments on commit c7d4614

Please sign in to comment.