Function reader [src]

HTTP protocol from server to client. This either comes directly from stream_reader, or from a TLS client.

Prototype

pub fn reader(c: *Connection) *Reader

Parameters

c: *Connection

Source

pub fn reader(c: *Connection) *Reader { return switch (c.protocol) { .tls => { if (disable_tls) unreachable; const tls: *Tls = @alignCast(@fieldParentPtr("connection", c)); return &tls.client.reader; }, .plain => c.stream_reader.interface(), }; }