private static HistogramBase CompressedEncodeDecode(HistogramBase source) { var targetBuffer = ByteBuffer.Allocate(source.GetNeededByteBufferCapacity()); source.EncodeIntoCompressedByteBuffer(targetBuffer); targetBuffer.Position = 0; return(HistogramEncoding.DecodeFromCompressedByteBuffer(targetBuffer, 0)); }
private static HistogramBase DecodeHistogram(ByteBuffer buffer, long minBarForHighestTrackableValue) { return(HistogramEncoding.DecodeFromCompressedByteBuffer(buffer, minBarForHighestTrackableValue)); }