Class: ShellBackend
- Inherits:
-
Object
- Object
- ShellBackend
- Defined in:
- lib/rhcp_shell/shell_backend.rb
Overview
responsible for what should happen when the user interacts with the shell provides tab completion options and processes the user’s input
Direct Known Subclasses
Instance Method Summary collapse
-
#complete(word) ⇒ Object
is called whenever the user requests tab completion should return an array of completion proposals.
- #process_ctrl_c ⇒ Object
-
#process_input(command_line) ⇒ Object
is called whenever the user submits a command (hitting enter).
-
#prompt ⇒ Object
is called by the shell to get the prompt that should be displayed.
- #show_banner ⇒ Object
Instance Method Details
#complete(word) ⇒ Object
is called whenever the user requests tab completion should return an array of completion proposals
12 13 14 |
# File 'lib/rhcp_shell/shell_backend.rb', line 12 def complete(word) raise "not implemented in ShellBackend!" end |
#process_ctrl_c ⇒ Object
21 22 23 |
# File 'lib/rhcp_shell/shell_backend.rb', line 21 def process_ctrl_c end |
#process_input(command_line) ⇒ Object
is called whenever the user submits a command (hitting enter)
6 7 8 |
# File 'lib/rhcp_shell/shell_backend.rb', line 6 def process_input(command_line) raise "not implemented in ShellBackend!" end |
#prompt ⇒ Object
is called by the shell to get the prompt that should be displayed
17 18 19 |
# File 'lib/rhcp_shell/shell_backend.rb', line 17 def prompt ">" end |
#show_banner ⇒ Object
25 26 27 |
# File 'lib/rhcp_shell/shell_backend.rb', line 25 def end |