Home / Docs / Standard library / std.host
HttpServer
Release v0.4.0Edition 0.4, 0.5 preview
A capability of the module std.host, which a module imports by name; the prelude does not put it in scope (spec/31 §1). Edition 0.4, 0.5 preview.
una
pub capability HttpServer
op next() -> internal Exchange
fails ServeError
accepts internal
op reply(to: ReplyRight, reply: Reply) -> Unit
fails ServeError
accepts internal
op close() -> Unit
accepts publicThe server side of HTTP/1.1, on the addresses that serve grants allow (spec/31 §1, ADR 0123 rules 1 to 5). next waits for a request and gives the calling task its reply right; reply answers it once and never waits; close stops accepting connections, and accepts public only, so no request decides it.
Specification
Generated from the standard modules of una v0.4.0 (docs/std/listing.json, which is not part of the specification). The specification governs: spec/14 §1.