/// This will parse the provided command and execute the task
This will parse the provided command and execute the task
This will parse the provided command and execute the task
pub fn handle_command(&mut self, command_str: &str, shutdown: &mut Shutdown) {
        if command_str.trim().is_empty() {
            return;
        }
        let del_arg_vec = delimit_command_string(command_str);
        let mut args = command_str.split_whitespace();
        let command = BaseNodeCommand::from_str(args.next().unwrap_or(&"help"));
        if command.is_err() {
            println!("{} is not a valid command, please enter a valid command", command_str);
            println!("Enter help or press tab for available commands");
            return;
        }
        let command = command.unwrap();
        self.process_command(command, args, del_arg_vec, shutdown);
    }
pub fn handle_command ( & mut self , command_str : & str , shutdown : & mut Shutdown ) { if command_str . trim ( ) . is_empty ( ) { return ; } let del_arg_vec = delimit_command_string ( command_str ) ; let mut args = command_str . split_whitespace ( ) ; let command = BaseNodeCommand :: from_str ( args . next ( ) . unwrap_or ( & " " ) ) ; if command . is_err ( ) { println ! ( " " command_str ) ; println ! ( " " ) ; return ; } let command = command . unwrap ( ) ; self . process_command ( command , args , del_arg_vec , shutdown ) ; }
This will parse the provided command and execute the task
This will parse the provided command and execute the task
&mut self
command_str
&str
shutdown
&mut Shutdown