pub struct Remote {
pub username: String,
pub hostname: String,
pub remote_path: String,
pub local_path: String,
pub current_path: String,
pub port: String,
}Expand description
Used to remember the setting of this remote. it’s used to mount the remote in the current directory using sshfs.
Fields§
§username: String§hostname: String§remote_path: String§local_path: String§current_path: String§port: StringImplementations§
Source§impl Remote
impl Remote
Sourcepub fn from_input(input: String, current_path: &str) -> Option<Self>
pub fn from_input(input: String, current_path: &str) -> Option<Self>
Converts an input like “username hostname:33 /remote/path /local/path” into
a separated list of arguments for sshfs.
Returns None if the input string can’t be parsed correctly.
Returns also None if “sshfs” isn’t in the current $PATH.
Auto Trait Implementations§
impl Freeze for Remote
impl RefUnwindSafe for Remote
impl Send for Remote
impl Sync for Remote
impl Unpin for Remote
impl UnsafeUnpin for Remote
impl UnwindSafe for Remote
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.