/// Creates a new queue with the given sample size and initial value used for the rolling
/// average
Creates a new queue with the given sample size and initial value used for the rolling
average
Creates a new queue with the given sample size and initial value used for the rolling average
pub fn new(
        sample_size: Option<usize>,
        initial_value: Option<usize>,
        multiplier: Option<usize>,
    ) -> Self {
        Self {
            batches: VecDeque::new(),
            ids: HashSet::new(),
            multiplier: multiplier.unwrap_or(DEFAULT_BATCH_QUEUE_MULTIPLIER),
            rolling_average: RollingAverage::new(
                sample_size.unwrap_or(DEFAULT_BATCH_QUEUE_SAMPLE_SIZE),
                initial_value.unwrap_or(DEFAULT_BATCH_QUEUE_INITIAL_SAMPLE_VALUE),
            ),
        }
    }
pub fn new ( sample_size : Option < usize > , initial_value : Option < usize > , multiplier : Option < usize > , ) -> Self { Self { batches : VecDeque :: new ( ) , ids : HashSet :: new ( ) , multiplier : multiplier . unwrap_or ( DEFAULT_BATCH_QUEUE_MULTIPLIER ) , rolling_average : RollingAverage :: new ( sample_size . unwrap_or ( DEFAULT_BATCH_QUEUE_SAMPLE_SIZE ) , initial_value . unwrap_or ( DEFAULT_BATCH_QUEUE_INITIAL_SAMPLE_VALUE ) , ) , } }
Creates a new queue with the given sample size and initial value used for the rolling
average
Creates a new queue with the given sample size and initial value used for the rolling average
sample_size
Option<usize>
initial_value
Option<usize>
multiplier
Option<usize>