| Linux premium331.web-hosting.com 4.18.0-553.80.1.lve.el8.x86_64 #1 SMP Wed Oct 22 19:29:36 UTC 2025 x86_64 Path : /home/livedhms/nodevenv/lmgt/22/lib/node_modules/effect/src/internal/schedule/ |
| Current File : /home/livedhms/nodevenv/lmgt/22/lib/node_modules/effect/src/internal/schedule/decision.ts |
import * as Chunk from "../../Chunk.js"
import type * as ScheduleDecision from "../../ScheduleDecision.js"
import type * as Interval from "../../ScheduleInterval.js"
import * as Intervals from "../../ScheduleIntervals.js"
/** @internal */
export const OP_CONTINUE = "Continue" as const
/** @internal */
export type OP_CONTINUE = typeof OP_CONTINUE
/** @internal */
export const OP_DONE = "Done" as const
/** @internal */
export type OP_DONE = typeof OP_DONE
/** @internal */
export const _continue = (intervals: Intervals.Intervals): ScheduleDecision.ScheduleDecision => {
return {
_tag: OP_CONTINUE,
intervals
}
}
/** @internal */
export const continueWith = (interval: Interval.Interval): ScheduleDecision.ScheduleDecision => {
return {
_tag: OP_CONTINUE,
intervals: Intervals.make(Chunk.of(interval))
}
}
/** @internal */
export const done: ScheduleDecision.ScheduleDecision = {
_tag: OP_DONE
}
/** @internal */
export const isContinue = (self: ScheduleDecision.ScheduleDecision): self is ScheduleDecision.Continue => {
return self._tag === OP_CONTINUE
}
/** @internal */
export const isDone = (self: ScheduleDecision.ScheduleDecision): self is ScheduleDecision.Done => {
return self._tag === OP_DONE
}