(dAtA []byte)
| 3248 | } |
| 3249 | |
| 3250 | func (m *Exemplar) MarshalToSizedBuffer(dAtA []byte) (int, error) { |
| 3251 | i := len(dAtA) |
| 3252 | _ = i |
| 3253 | var l int |
| 3254 | _ = l |
| 3255 | if m.TimestampMs != 0 { |
| 3256 | i = encodeVarintCortex(dAtA, i, uint64(m.TimestampMs)) |
| 3257 | i-- |
| 3258 | dAtA[i] = 0x18 |
| 3259 | } |
| 3260 | if m.Value != 0 { |
| 3261 | i -= 8 |
| 3262 | encoding_binary.LittleEndian.PutUint64(dAtA[i:], uint64(math.Float64bits(float64(m.Value)))) |
| 3263 | i-- |
| 3264 | dAtA[i] = 0x11 |
| 3265 | } |
| 3266 | if len(m.Labels) > 0 { |
| 3267 | for iNdEx := len(m.Labels) - 1; iNdEx >= 0; iNdEx-- { |
| 3268 | { |
| 3269 | size := m.Labels[iNdEx].Size() |
| 3270 | i -= size |
| 3271 | if _, err := m.Labels[iNdEx].MarshalTo(dAtA[i:]); err != nil { |
| 3272 | return 0, err |
| 3273 | } |
| 3274 | i = encodeVarintCortex(dAtA, i, uint64(size)) |
| 3275 | } |
| 3276 | i-- |
| 3277 | dAtA[i] = 0xa |
| 3278 | } |
| 3279 | } |
| 3280 | return len(dAtA) - i, nil |
| 3281 | } |
| 3282 | |
| 3283 | func (m *Histogram) Marshal() (dAtA []byte, err error) { |
| 3284 | size := m.Size() |
no test coverage detected