ChannelSchema overview
Added in v1.0.0
Table of contents
combinators
duplex
Signature
export declare const duplex: {
<IA, II, IR, OA, OI, OR>(options: {
readonly inputSchema: Schema.Schema<IA, II, IR>
readonly outputSchema: Schema.Schema<OA, OI, OR>
}): <R, InErr, OutErr, OutDone, InDone>(
self: Channel.Channel<Chunk.Chunk<OI>, Chunk.Chunk<II>, OutErr, ParseError | InErr, OutDone, InDone, R>
) => Channel.Channel<Chunk.Chunk<OA>, Chunk.Chunk<IA>, ParseError | OutErr, InErr, OutDone, InDone, R | IR | OR>
<R, InErr, OutErr, OutDone, InDone, IA, II, IR, OA, OI, OR>(
self: Channel.Channel<Chunk.Chunk<OI>, Chunk.Chunk<II>, OutErr, ParseError | InErr, OutDone, InDone, R>,
options: { readonly inputSchema: Schema.Schema<IA, II, IR>; readonly outputSchema: Schema.Schema<OA, OI, OR> }
): Channel.Channel<Chunk.Chunk<OA>, Chunk.Chunk<IA>, ParseError | OutErr, InErr, OutDone, InDone, R | IR | OR>
}
Added in v1.0.0
duplexUnknown
Signature
export declare const duplexUnknown: {
<IA, II, IR, OA, OI, OR>(options: {
readonly inputSchema: Schema.Schema<IA, II, IR>
readonly outputSchema: Schema.Schema<OA, OI, OR>
}): <R, InErr, OutErr, OutDone, InDone>(
self: Channel.Channel<Chunk.Chunk<unknown>, Chunk.Chunk<any>, OutErr, ParseError | InErr, OutDone, InDone, R>
) => Channel.Channel<Chunk.Chunk<OA>, Chunk.Chunk<IA>, ParseError | OutErr, InErr, OutDone, InDone, R | IR | OR>
<R, InErr, OutErr, OutDone, InDone, IA, II, IR, OA, OI, OR>(
self: Channel.Channel<Chunk.Chunk<unknown>, Chunk.Chunk<any>, OutErr, ParseError | InErr, OutDone, InDone, R>,
options: { readonly inputSchema: Schema.Schema<IA, II, IR>; readonly outputSchema: Schema.Schema<OA, OI, OR> }
): Channel.Channel<Chunk.Chunk<OA>, Chunk.Chunk<IA>, ParseError | OutErr, InErr, OutDone, InDone, R | IR | OR>
}
Added in v1.0.0
constructors
decode
Signature
export declare const decode: <A, I, R>(
schema: Schema.Schema<A, I, R>
) => <IE = never, Done = unknown>() => Channel.Channel<
Chunk.Chunk<A>,
Chunk.Chunk<I>,
ParseError | IE,
IE,
Done,
Done,
R
>
Added in v1.0.0
decodeUnknown
Signature
export declare const decodeUnknown: <A, I, R>(
schema: Schema.Schema<A, I, R>
) => <IE = never, Done = unknown>() => Channel.Channel<
Chunk.Chunk<A>,
Chunk.Chunk<any>,
ParseError | IE,
IE,
Done,
Done,
R
>
Added in v1.0.0
encode
Signature
export declare const encode: <A, I, R>(
schema: Schema.Schema<A, I, R>
) => <IE = never, Done = unknown>() => Channel.Channel<
Chunk.Chunk<I>,
Chunk.Chunk<A>,
IE | ParseError,
IE,
Done,
Done,
R
>
Added in v1.0.0
encodeUnknown
Signature
export declare const encodeUnknown: <A, I, R>(
schema: Schema.Schema<A, I, R>
) => <IE = never, Done = unknown>() => Channel.Channel<
Chunk.Chunk<unknown>,
Chunk.Chunk<A>,
IE | ParseError,
IE,
Done,
Done,
R
>
Added in v1.0.0