clang-tools
11.0.0
|
A consumer of trace events and measurements. More...
#include <Trace.h>
Public Member Functions | |
virtual | ~EventTracer ()=default |
virtual Context | beginSpan (llvm::StringRef Name, llvm::json::Object *Args) |
Called when event that has a duration starts. More... | |
virtual void | endSpan () |
virtual void | instant (llvm::StringRef Name, llvm::json::Object &&Args) |
Called for instant events. More... | |
virtual void | record (const Metric &Metric, double Value, llvm::StringRef Label) |
Called whenever a metrics records a measurement. More... | |
A consumer of trace events and measurements.
The events are produced by Spans and trace::log, the measurements are produced by Metrics::record. Implementations of this interface must be thread-safe.
|
virtualdefault |
|
virtual |
Called when event that has a duration starts.
Name
describes the event. Returns a derived context that will be destroyed when the event ends. Usually implementations will store an object in the returned context whose destructor records the end of the event. The args are *Args, only complete when the event ends.
|
inlinevirtual |
|
inlinevirtual |
|
inlinevirtual |
Called whenever a metrics records a measurement.
Reimplemented in clang::clangd::trace::TestTracer.