StreamHaltStrategy
Constructors
Signature
declare const Both: HaltStrategy;Signature
declare const Either: HaltStrategy;Signature
declare const fromInput: (input: HaltStrategyInput) => HaltStrategy;Signature
declare const Left: HaltStrategy;Signature
declare const Right: HaltStrategy;Folding
Signature
declare const match: {
<Z>(options: {
readonly onBoth: () => Z;
readonly onEither: () => Z;
readonly onLeft: () => Z;
readonly onRight: () => Z;
}): (self: HaltStrategy) => Z;
<Z>(
self: HaltStrategy,
options: {
readonly onBoth: () => Z;
readonly onEither: () => Z;
readonly onLeft: () => Z;
readonly onRight: () => Z;
},
): Z;
};Models
Signature
interface Both {
readonly _tag: "Both";
}Signature
interface Either {
readonly _tag: "Either";
}HaltStrategy type
Added in v2.0.0
Source
Signature
type HaltStrategy = Left | Right | Both | Either;HaltStrategyInput type
Added in v2.0.0
Source
Signature
type HaltStrategyInput = HaltStrategy | "left" | "right" | "both" | "either";Signature
interface Left {
readonly _tag: "Left";
}Signature
interface Right {
readonly _tag: "Right";
}Refinements
Signature
declare const isBoth: (self: HaltStrategy) => self is Both;Signature
declare const isEither: (self: HaltStrategy) => self is Either;Signature
declare const isLeft: (self: HaltStrategy) => self is Left;Signature
declare const isRight: (self: HaltStrategy) => self is Right;
Folds over the specified
HaltStrategyusing the provided case functions.