CustomBucketsHistogramSamples appends the encoded custom-bucket histogram samples to b and returns the resulting slice.
(histograms []RefHistogramSample, b []byte)
| 1151 | // CustomBucketsHistogramSamples appends the encoded custom-bucket histogram |
| 1152 | // samples to b and returns the resulting slice. |
| 1153 | func (e *Encoder) CustomBucketsHistogramSamples(histograms []RefHistogramSample, b []byte) []byte { |
| 1154 | if e.EnableSTStorage { |
| 1155 | return e.histogramSamplesV2(histograms, b) |
| 1156 | } |
| 1157 | return e.customBucketsHistogramSamplesV1(histograms, b) |
| 1158 | } |
| 1159 | |
| 1160 | func (*Encoder) customBucketsHistogramSamplesV1(histograms []RefHistogramSample, b []byte) []byte { |
| 1161 | buf := encoding.Encbuf{B: b} |