encode(to:)
Encodes the operation as a keyed container with a type discriminator and either metric (the metric name) or label (for custom operations).
Declaration
func encode(to encoder: any Encoder) throwsEncodes the operation as a keyed container with a type discriminator and either metric (the metric name) or label (for custom operations).
func encode(to encoder: any Encoder) throws