pub fn stop(&mut self, error_code: VarInt) -> Result<(), UnknownStream> {
        let mut conn = self.conn.lock().unwrap();
        if self.is_0rtt && conn.check_0rtt().is_err() {
            return Ok(());
        }
        conn.inner.stop(self.stream, error_code)?;
        conn.wake();
        self.all_data_read = true;
        Ok(())
    }
/// Stop accepting data
///
/// Discards unread data and notifies the peer to stop transmitting. Once stopped, a stream
/// cannot be read from any further.
Stop accepting data
Discards unread data and notifies the peer to stop transmitting. Once stopped, a stream
cannot be read from any further.
Stop accepting data Discards unread data and notifies the peer to stop transmitting . Once stopped a stream cannot be read from any further .
pub fn stop(&mut self, error_code: VarInt) -> Result<(), UnknownStream> {
        let mut conn = self.conn.lock().unwrap();
        if self.is_0rtt && conn.check_0rtt().is_err() {
            return Ok(());
        }
        conn.inner.stop(self.stream, error_code)?;
        conn.wake();
        self.all_data_read = true;
        Ok(())
    }
pub fn stop ( & mut self , error_code : VarInt ) -> Result < ( ) , UnknownStream > { let mut conn = self . conn . lock ( ) . unwrap ( ) ; if self . is_0rtt && conn . check_0rtt ( ) . is_err ( ) { return Ok ( ( ) ) ; } conn . inner . stop ( self . stream , error_code ) ? ; conn . wake ( ) ; self . all_data_read = true ; Ok ( ( ) ) }
Stop accepting data
Discards unread data and notifies the peer to stop transmitting.
Stop accepting data Discards unread data and notifies the peer to stop transmitting .
&mut self
error_code
VarInt