mirror of
https://github.com/apple/swift-nio-http2
synced 2026-11-25 04:47:50 +00:00
Motivation: As part of #214 we need to make `HTTP2StreamChannel` generic over the type of message it expects to read and write. This allows us to define an `HTTP2StreamChannel` which uses `HTTP2Frame.FramePayload` as its currency type, rather than `HTTP2Frame`. Modifications: - Make `HTTP2StreamChannel` generic over `Message` which is constrained by conformance to `HTTP2FrameConvertible` and `HTTP2FramePayloadConvertible` - `HTTP2StreamChannel` now expects to read in `Message`s (as opposed to `HTTP2Frame`s) and have `Message`s written in to it. - Added typealiases for frame and payload based stream channels. - Added support for the payload based channel in `MultiplexerAbstractChannel` (although one can't be created yet). Result: We can create payload based stream channels. Co-authored-by: Cory Benfield <lukasa@apple.com>