CauseIso<E, D>Iso representation used for Cause schemas: an ordered array of
CauseReasonIso values.
When to use
Use when working with the ISO shape of a Cause schema, such as toIso
optics or codecs that expose a cause as its ordered array of encoded reasons.
Source effect/Schema.ts:92981 lines
export type type CauseIso<
E extends Constraint,
D extends Constraint
> = readonly CauseReasonIso<E, D>[]
Iso representation used for Cause schemas: an ordered array of
CauseReasonIso values.
When to use
Use when working with the ISO shape of a Cause schema, such as toIso
optics or codecs that expose a cause as its ordered array of encoded reasons.
CauseIso<function (type parameter) E in type CauseIso<E extends Constraint, D extends Constraint>E extends Constraint, function (type parameter) D in type CauseIso<E extends Constraint, D extends Constraint>D extends Constraint> = interface ReadonlyArray<T>ReadonlyArray<type CauseReasonIso<
E extends Constraint,
D extends Constraint
> =
| {
readonly _tag: "Fail"
readonly error: E["Iso"]
}
| {
readonly _tag: "Die"
readonly error: D["Iso"]
}
| {
readonly _tag: "Interrupt"
readonly fiberId: number | undefined
}
Iso representation used for CauseReason schemas.
Details
Failures are represented with a Fail tag and encoded error, defects with a
Die tag and encoded defect, and interrupts with an optional fiberId.
CauseReasonIso<function (type parameter) E in type CauseIso<E extends Constraint, D extends Constraint>E, function (type parameter) D in type CauseIso<E extends Constraint, D extends Constraint>D>>Referenced by 3 symbols