Struct t_ssh_client::Session
source · [−]pub struct Session { /* private fields */ }
Implementations
sourceimpl Session
impl Session
pub async fn connect(addr: &str, timeout: Duration) -> Result<Session, Error>
pub async fn auth_with_password(
&mut self,
username: &str,
password: &str
) -> Result<(), Error>
pub async fn execute(&mut self, command: &str) -> Result<Output, Error>
pub async fn close(&mut self) -> Result<(), Error>
Auto Trait Implementations
impl !RefUnwindSafe for Session
impl Send for Session
impl Sync for Session
impl Unpin for Session
impl !UnwindSafe for Session
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more