deliver_and_flush

Function deliver_and_flush 

pub(super) async fn deliver_and_flush<W: AsyncWrite + Unpin>(
    pending_messages: &mut VecDeque<Message>,
    msg_tx: &Sender<Message>,
    graceful: bool,
    write: &mut W,
    outbound: &mut PacketWriter<GrowBuffer>,
)
Expand description

Delivers buffered messages to the application (they are acknowledged and owed to it) and, on a graceful close, flushes any remaining outbound bytes.