def stream.fresh

bend-kit-http@0.38.5.0 · http.bend:4980

import bend-kit-http@0.38.5.0/http.bend as Http
import Base
import bend-kit-bytes@0.3.3.0/bytes.bend as Bytes

4980# A new connection, with no h2 offer.
4981def stream.fresh(+ms: U32, +head: Bool, back: Maybe<&2, String>, route: Route, wire: Bytes.Bytes) -> IO(Result<&1, &1, Err, Stream>):
4982  do IO<Result<&1, &1, Err, Stream>>:
4983    c : Result<&1, &1, Err, Conn> <- route.open(ms, False{}, route)
4984    x : Bool & Result<&1, &1, Err, Stream> <- stream.conn(c, ms, head, back, wire)
4985    return stream.opened(x)

Uses (17)

Used by (3)