pub fn is_within_window(&self, ack: u16, window_position: u16, log: Box<&dyn Loggable>) -> bool {
        // get window borders
        let window_start = Wrapping(window_position);
        let window_end = window_start + Wrapping(self.window_size);
        // check if the window overlap over the range
        let is_within = match window_start < window_end {
            true => ack >= window_position && ack < window_position + self.window_size,
            false => window_position <= ack || ack < window_end.0,
        };
        // return the result
        log.vlog(&format!(
            "Check whether {} is within window starting at {} of size {}: {}",
            ack,
            window_position,
            self.window_size,
            is_within
        ));
        return is_within;
    }
/// Check whether the `ack` number is within windows starting at `window_position` and specified by this connection.
Check whether the `ack` number is within windows starting at `window_position` and specified by this connection.
Check whether the ` ack ` number is within windows starting at ` window_position ` and specified by this connection .
pub fn is_within_window(&self, ack: u16, window_position: u16, log: Box<&dyn Loggable>) -> bool {
        // get window borders
        let window_start = Wrapping(window_position);
        let window_end = window_start + Wrapping(self.window_size);
        // check if the window overlap over the range
        let is_within = match window_start < window_end {
            true => ack >= window_position && ack < window_position + self.window_size,
            false => window_position <= ack || ack < window_end.0,
        };
        // return the result
        log.vlog(&format!(
            "Check whether {} is within window starting at {} of size {}: {}",
            ack,
            window_position,
            self.window_size,
            is_within
        ));
        return is_within;
    }
pub fn is_within_window ( & self , ack : u16 , window_position : u16 , log : Box < & dyn Loggable > ) -> bool { // get window borders let window_start = Wrapping ( window_position ) ; let window_end = window_start + Wrapping ( self . window_size ) ; // check if the window overlap over the range let is_within = match window_start < window_end { true => ack >= window_position && ack < window_position + self . window_size , false => window_position <= ack || ack < window_end . 0 , } ; // return the result log . vlog ( & format ! ( " " ack window_position self window_size is_within ) ) ; return is_within ; }
Check whether the `ack` number is within windows starting at `window_position` and specified by this connection.
Check whether the ` ack ` number is within windows starting at ` window_position ` and specified by this connection .
&self
ack
u16
window_position
u16
log
Box<&dyn Loggable>
&self
ack
u16
window_position
u16
log
Box<&dyn Loggable>