public sealed class SpanContext : IMessage<SpanContext>, IEquatable<SpanContext>, IDeepCloneable<SpanContext>, IBufferMessage, IMessage
Reference documentation and code samples for the Google Cloud Monitoring v3 API class SpanContext.
The context of a span. This is attached to an
[Exemplar][google.api.Distribution.Exemplar]
in [Distribution][google.api.Distribution] values during aggregation.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[[["\u003cp\u003eThis webpage provides documentation for the \u003ccode\u003eSpanContext\u003c/code\u003e class within the Google Cloud Monitoring v3 API for .NET, with the latest version being 3.15.0.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eSpanContext\u003c/code\u003e represents the context of a span, which is attached to an Exemplar in Distribution values during aggregation.\u003c/p\u003e\n"],["\u003cp\u003eThe class \u003ccode\u003eSpanContext\u003c/code\u003e implements interfaces such as \u003ccode\u003eIMessage\u003c/code\u003e, \u003ccode\u003eIEquatable\u003c/code\u003e, \u003ccode\u003eIDeepCloneable\u003c/code\u003e, and \u003ccode\u003eIBufferMessage\u003c/code\u003e, inheriting from the \u003ccode\u003eobject\u003c/code\u003e class.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eSpanContext\u003c/code\u003e class has one main property, \u003ccode\u003eSpanName\u003c/code\u003e, which is a string representing the resource name of the span and follows a specific format including the project ID or number, trace ID, and span ID.\u003c/p\u003e\n"],["\u003cp\u003eConstructors are provided for creating instances of the \u003ccode\u003eSpanContext\u003c/code\u003e class, including a default constructor and one that takes another \u003ccode\u003eSpanContext\u003c/code\u003e object as a parameter.\u003c/p\u003e\n"]]],[],null,[]]