def BaseContext.state

bend-trace-context@0.2.0.0 · trace_context.bend:3149

import bend-trace-context@0.2.0.0/trace_context.bend as TraceContext
import Base

3149# The state that goes with the base: the state received with an incoming
3150# context, or the state an outgoing context sends.
3151def BaseContext.state(base: BaseContext) -> TraceState:
3152  match base:
3153    case IncomingBase{incoming}:
3154      IncomingContext.state(incoming)
3155    case OutgoingBase{outgoing}:
3156      OutgoingContext.state(outgoing)

Uses (4)

Used by (1)