|
Aria 3.2.6
C++23 MVVM framework — reactive, coroutine-first, ABI-layered
|
HTTP/REST/SSE implementation of IViewAdapter. More...
#include "aria/abi/export.hpp"#include "aria/binding/view_adapter.hpp"#include "http_config.hpp"#include "http_view.hpp"#include <cstdint>#include <functional>#include <memory>#include <string>#include <string_view>#include <vector>Go to the source code of this file.
Classes | |
| class | aria::adapters::http::HttpAdapter |
| HTTP/REST/SSE implementation of IViewAdapter. More... | |
| struct | aria::adapters::http::HttpAdapter::ViewInfo |
| Snapshot of currently registered (id, kind) pairs. More... | |
Namespaces | |
| namespace | aria |
| namespace | aria::adapters |
| namespace | aria::adapters::http |
HTTP/REST/SSE implementation of IViewAdapter.
HttpAdapter is the "Web sibling" of QtAdapter / AppKitAdapter / UIKitAdapter. It exposes Aria ViewModels to a remote frontend (typically a browser running plain JS or Vue/React/Svelte) over a small REST + SSE protocol — see wire_protocol.hpp.
The transport layer is Mira (https://github.com/dqsjqian/Mira), a coroutine-native C++23 networking library: an event loop runs the accept loop and every connection as a coroutine, so SSE streams no longer occupy a worker thread per client. Request routing and user callbacks still run on the adapter's worker pool.
See docs/guide/adapters/http.md for a compiled complete example. Construct a shared HttpAdapter and pass it with the graph owner's dispatcher to BindingEngine using DispatchPolicy::SmartMarshal.