Trait ngrok::tunnel::TunnelCloser

source ·
pub trait TunnelCloser {
    // Required method
    fn close<'life0, 'async_trait>(
        &'life0 mut self
    ) -> Pin<Box<dyn Future<Output = Result<(), RpcError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

An ngrok tunnel closer.

Required Methods§

source

fn close<'life0, 'async_trait>( &'life0 mut self ) -> Pin<Box<dyn Future<Output = Result<(), RpcError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Close the tunnel.

This is an RPC call that must be .awaited. It is equivalent to calling Session::close_tunnel with this tunnel’s ID.

If the tunnel is dropped, a task will be spawned to close it asynchronously.

Implementors§