28 #if ! defined (octave_input_h)
29 #define octave_input_h 1
31 #include "octave-config.h"
50 OCTAVE_DEPRECATED (6,
"'Vtrack_line_num' is an obsolete internal variable; any uses should be removed")
71 std::string
PS1 (
void)
const {
return m_PS1; }
73 std::string
PS1 (
const std::string& s)
75 std::string val = m_PS1;
80 void set_PS1 (
const std::string& s) { m_PS1 = s; }
84 std::string
PS2 (
void)
const {
return m_PS2; }
86 std::string
PS2 (
const std::string& s)
88 std::string val = m_PS2;
93 void set_PS2 (
const std::string& s) { m_PS2 = s; }
97 return m_last_debugging_command;
102 std::string val = m_last_debugging_command;
103 m_last_debugging_command = s;
112 return m_completion_append_char;
117 char val = m_completion_append_char;
118 m_completion_append_char = c;
130 bool val = m_gud_mode;
143 std::string val = m_mfile_encoding;
144 m_mfile_encoding = s;
155 return m_auto_repeat_debug_command;
160 bool old_val = m_auto_repeat_debug_command;
161 m_auto_repeat_debug_command = val;
224 : m_interpreter (interp)
228 : m_interpreter (
x.m_interpreter)
233 virtual std::string
get_input (
const std::string& prompt,
bool& eof) = 0;
270 std::string
get_input (
const std::string& prompt,
bool& eof)
272 return m_rep->get_input (prompt, eof);
277 return m_rep->input_source ();
282 return m_rep->input_from_terminal ();
287 return m_rep->input_from_file ();
292 return m_rep->input_from_eval_string ();
301 #if defined (OCTAVE_USE_DEPRECATED_FUNCTIONS)
303 OCTAVE_DEPRECATED (5,
"use 'octave::input_system::yes_or_no' instead")
304 extern
bool octave_yes_or_no (const std::
string& prompt);
306 OCTAVE_DEPRECATED (5, "use '
octave::input_system::clear_input_event_hooks' instead")
307 extern
void remove_input_event_hook_functions (
void);
309 OCTAVE_DEPRECATED (5, "this function will be removed in a future version of Octave")
310 extern OCTINTERP_API FILE * get_input_from_stdin (
void);
base_reader(const base_reader &x)
virtual std::string get_input(const std::string &prompt, bool &eof)=0
virtual bool input_from_file(void) const
interpreter & m_interpreter
virtual ~base_reader(void)=default
virtual std::string input_source(void) const
base_reader(interpreter &interp)
virtual bool input_from_terminal(void) const
std::string octave_gets(const std::string &prompt, bool &eof)
virtual bool input_from_eval_string(void) const
static const std::string s_in_src
F77_RET_T const F77_DBLE * x