Creates a new ring buffer
(capacity: NonZeroUsize)
| 50 | |
| 51 | /// Creates a new ring buffer |
| 52 | pub fn new(capacity: NonZeroUsize) -> Self { |
| 53 | Self { |
| 54 | inner: RingBuffer::new(capacity), |
| 55 | rtt_threshold_multiplier: 5, |
| 56 | window: Self::SKM_WINDOW, |
| 57 | } |
| 58 | } |
| 59 | |
| 60 | pub fn with_window(capacity: NonZeroUsize, window: Duration) -> Self { |
| 61 | Self { |