36class FontFlightRecorder {
45 std::vector<FallbackTraceRecord>
drain();
48 std::vector<FallbackTraceRecord>
snapshot()
const;
63 ~FontFlightRecorder();
64 FontFlightRecorder(const FontFlightRecorder&) = delete;
65 FontFlightRecorder& operator=(const FontFlightRecorder&) = delete;
68 std::unique_ptr<Impl> impl_;
void clear()
Drop all buffered records.
void set_capacity(std::size_t capacity)
Set the ring-buffer capacity.
std::vector< FallbackTraceRecord > snapshot() const
Snapshot only (does not clear). Returns oldest-first.
static FontFlightRecorder & instance()
std::size_t capacity() const noexcept
std::size_t size() const noexcept
Number of records currently buffered.
std::vector< FallbackTraceRecord > drain()
Snapshot + clear the buffered records. Returns oldest-first.
void record_fallback(const FallbackTraceRecord &record)
Append a resolution event.
Definition affine_transform.hpp:24
std::string flight_recorder_drain_json()
Convenience: drain the global recorder and emit one JSON object per record to out.
One resolution event.
Definition font_flight_recorder.hpp:28
std::string requested_family
Definition font_flight_recorder.hpp:29
std::uint8_t origin
matches FallbackOrigin enum cast to u8
Definition font_flight_recorder.hpp:31
std::string selected_family
Definition font_flight_recorder.hpp:30
std::uint64_t generation
registry generation at resolve time
Definition font_flight_recorder.hpp:32
std::uint64_t sequence
monotonic per-recorder sequence number
Definition font_flight_recorder.hpp:33