Package brave.propagation.tracecontext
Class TraceparentFormat
- java.lang.Object
-
- brave.propagation.tracecontext.TraceparentFormat
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static TraceparentFormatget()brave.propagation.TraceContextparse(CharSequence parent)brave.propagation.TraceContextparse(CharSequence value, int beginIndex, int endIndex)This reads a trace context a sequence potentially larger than the format.Stringwrite(brave.propagation.TraceContext context)Writes all "traceparent" defined fields in the trace context to a hyphen delimited string.byte[]writeAsBytes(brave.propagation.TraceContext context)Likewrite(TraceContext), but for requests with byte array or byte buffer values.
-
-
-
Method Detail
-
get
public static TraceparentFormat get()
-
write
public String write(brave.propagation.TraceContext context)
Writes all "traceparent" defined fields in the trace context to a hyphen delimited string.
-
writeAsBytes
public byte[] writeAsBytes(brave.propagation.TraceContext context)
Likewrite(TraceContext), but for requests with byte array or byte buffer values. For example,ByteBuffer.wrap(byte[])can wrap the result.
-
parse
@Nullable public brave.propagation.TraceContext parse(CharSequence parent)
-
parse
@Nullable public brave.propagation.TraceContext parse(CharSequence value, int beginIndex, int endIndex)
This reads a trace context a sequence potentially larger than the format. The use-case is reducing garbage, by re-using the inputvalueacross multiple parse operations.
-
-