[][src]Trait opentelemetry::api::trace::propagator::BinaryFormat

pub trait BinaryFormat {
    fn to_bytes(&self, context: &SpanContext) -> [u8; 29];
fn from_bytes(&self, bytes: Vec<u8>) -> SpanContext; }

Used to serialize and deserialize SpanContexts to and from a binary representation.

Required methods

fn to_bytes(&self, context: &SpanContext) -> [u8; 29]

Serializes span context into a byte array and returns the array.

fn from_bytes(&self, bytes: Vec<u8>) -> SpanContext

Deserializes a span context from a byte array.

Loading content...

Implementors

impl BinaryFormat for BinaryPropagator[src]

fn to_bytes(&self, context: &SpanContext) -> [u8; 29][src]

Serializes span context into a byte array and returns the array.

fn from_bytes(&self, bytes: Vec<u8>) -> SpanContext[src]

Deserializes a span context from a byte array.

Loading content...