source: trip-planner-front/node_modules/hdr-histogram-js/assembly/AbstractHistogramBase.ts@ 188ee53

Last change on this file since 188ee53 was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 1.5 KB
Line 
1/*
2 * This is a AssemblyScript port of the original Java version, which was written by
3 * Gil Tene as described in
4 * https://github.com/HdrHistogram/HdrHistogram
5 * and released to the public domain, as explained at
6 * http://creativecommons.org/publicdomain/zero/1.0/
7 */
8
9import RecordedValuesIterator from "./RecordedValuesIterator";
10import PercentileIterator from "./PercentileIterator";
11
12export const NO_TAG = "NO TAG";
13
14export abstract class AbstractHistogramBase<T, U> {
15 static identityBuilder: number;
16
17 identity: f64;
18 autoResize: boolean = false;
19
20 highestTrackableValue: u64;
21 lowestDiscernibleValue: u64;
22 numberOfSignificantValueDigits: u8;
23
24 bucketCount: u64;
25 /**
26 * Power-of-two length of linearly scaled array slots in the counts array. Long enough to hold the first sequence of
27 * entries that must be distinguished by a single unit (determined by configured precision).
28 */
29 subBucketCount: i32;
30 countsArrayLength: i32;
31 wordSizeInBytes: u64;
32
33 startTimeStampMsec: u64 = u64.MAX_VALUE;
34 endTimeStampMsec: u64 = 0;
35 tag: string = NO_TAG;
36
37 integerToDoubleValueConversionRatio: f64 = 1.0;
38
39 percentileIterator: PercentileIterator<T, U>;
40 recordedValuesIterator: RecordedValuesIterator<T, U>;
41
42 constructor() {
43 this.identity = 0;
44 this.highestTrackableValue = 0;
45 this.lowestDiscernibleValue = 0;
46 this.numberOfSignificantValueDigits = 0;
47 this.bucketCount = 0;
48 this.subBucketCount = 0;
49 this.countsArrayLength = 0;
50 this.wordSizeInBytes = 0;
51 }
52}
Note: See TracBrowser for help on using the repository browser.