def client.settings.item

bend-kit-http2@0.4.0.0 · http2.bend:593

import bend-kit-http2@0.4.0.0/http2.bend as Http2
import Base
import bend-kit-http2@0.4.0.0/hpack.bend as Hpack

593def client.settings.item(id: U32, +value: U32, c: Client) -> Reply:
594  match id:
595    case 1:
596      Client{input, streams, encoder, decoder, control} = c
597      client.ok(Client{input, streams, Hpack.set_limit(value, encoder), decoder, control})
598    case 2:
599      client.fail(1, True{}, 0)
600    case 3:
601      Client{input, streams, encoder, decoder,
602        Control{next, active, frame_max, initial, max_streams, send_window, recv_window,
603          first, ack, continuation, goaway}} = c
604      client.ok(Client{input, streams, encoder, decoder,
605        Control{next, active, frame_max, initial, Some{value}, send_window, recv_window,
606          first, ack, continuation, goaway}})
607    case 4:
608      client.settings.initial(value, c)
609    case 5:
610      Client{input, streams, encoder, decoder,
611        Control{next, active, frame_max, initial, max_streams, send_window, recv_window,
612          first, ack, continuation, goaway}} = c
613      client.ok(Client{input, streams, encoder, decoder,
614        Control{next, active, value, initial, max_streams, send_window, recv_window,
615          first, ack, continuation, goaway}})
616    case _:
617      client.ok(c)

Uses (12)

Used by (1)