26 #if ! defined (octave_octave_h)
27 #define octave_octave_h 1
29 #include "octave-config.h"
55 int sys_argc (
void)
const {
return m_all_args.numel (); }
56 char **
sys_argv (
void)
const {
return m_all_args.c_str_vec (); }
61 {
return m_experimental_terminal_widget; }
64 bool gui (
void)
const {
return m_gui; }
66 {
return m_inhibit_startup_message; }
70 bool persist (
void)
const {
return m_persist; }
74 bool server (
void)
const {
return m_server; }
80 {
return m_command_line_path; }
83 std::string
exec_path (
void)
const {
return m_exec_path; }
84 std::string
image_path (
void)
const {
return m_image_path; }
85 std::string
info_file (
void)
const {
return m_info_file; }
94 { m_experimental_terminal_widget =
arg; }
112 { m_command_line_path =
arg; }
129 bool m_echo_commands =
false;
133 bool m_experimental_terminal_widget =
false;
141 bool m_forced_interactive =
false;
145 bool m_forced_line_editing =
false;
149 bool m_inhibit_startup_message =
false;
153 bool m_line_editing =
true;
157 bool m_no_window_system =
false;
161 bool m_persist =
false;
165 bool m_read_history_file =
true;
169 bool m_read_init_files =
true;
173 bool m_read_site_files =
true;
177 bool m_server =
false;
181 bool m_set_initial_path =
true;
185 bool m_traditional =
false;
189 bool m_verbose_flag =
false;
260 int sys_argc (
void)
const {
return m_options.sys_argc (); }
261 char **
sys_argv (
void)
const {
return m_options.sys_argv (); }
263 void set_program_names (
const std::string& pname);
275 bool interpreter_initialized (
void);
279 virtual void initialize_interpreter (
void);
281 virtual int execute_interpreter (
void);
283 virtual void delete_interpreter (
void);
291 { m_program_invocation_name = nm; }
299 bool experimental_terminal_widget (
void)
const;
305 return s_instance ? s_instance->m_program_invocation_name :
"";
310 return s_instance ? s_instance->m_program_name :
"";
320 return s_instance ? s_instance->gui_running () :
false;
325 static bool forced_interactive (
void);
351 bool m_have_eval_option_code =
false;
355 bool m_have_script_file =
false;
360 bool m_is_octave_program =
false;
static application * app(void)
cmdline_options options(void) const
static string_vector argv(void)
application(const application &)=delete
void forced_interactive(bool arg)
virtual bool gui_running(void) const
void program_name(const std::string &nm)
static std::string program_invocation_name(void)
char ** sys_argv(void) const
virtual void gui_running(bool)
static bool is_gui_running(void)
bool is_octave_program(void) const
bool have_script_file(void) const
void program_invocation_name(const std::string &nm)
static application * s_instance
std::string m_program_name
bool have_eval_option_code(void) const
std::unique_ptr< interpreter > m_interpreter
static std::string program_name(void)
cmdline_options m_options
virtual int execute(void)=0
std::string m_program_invocation_name
cli_application(const cmdline_options &opts=cmdline_options())
cli_application(const cli_application &)=delete
cli_application(int argc, char **argv)
~cli_application(void)=default
std::string info_file(void) const
std::string docstrings_file(void) const
std::list< std::string > m_command_line_path
std::string m_doc_cache_file
string_vector m_remaining_args
std::string m_texi_macros_file
bool line_editing(void) const
std::string doc_cache_file(void) const
std::string texi_macros_file(void) const
void forced_interactive(bool arg)
string_vector remaining_args(void) const
std::string m_info_program
bool verbose_flag(void) const
bool no_window_system(void) const
std::string exec_path(void) const
void info_program(const std::string &arg)
void image_path(const std::string &arg)
char ** sys_argv(void) const
string_vector all_args(void) const
bool traditional(void) const
void traditional(bool arg)
void doc_cache_file(const std::string &arg)
cmdline_options(const cmdline_options &)=default
bool forced_interactive(void) const
void docstrings_file(const std::string &arg)
void all_args(const string_vector &arg)
std::string code_to_eval(void) const
void inhibit_startup_message(bool arg)
bool read_site_files(void) const
void echo_commands(bool arg)
void set_initial_path(bool arg)
void remaining_args(const string_vector &arg)
void experimental_terminal_widget(bool arg)
bool experimental_terminal_widget(void) const
void read_site_files(bool arg)
void code_to_eval(const std::string &arg)
void verbose_flag(bool arg)
void read_history_file(bool arg)
bool forced_line_editing(void) const
void forced_line_editing(bool arg)
bool read_history_file(void) const
bool set_initial_path(void) const
std::list< std::string > command_line_path(void) const
void command_line_path(const std::list< std::string > &arg)
std::string info_program(void) const
void line_editing(bool arg)
void texi_macros_file(const std::string &arg)
std::string image_path(void) const
void read_init_files(bool arg)
std::string m_code_to_eval
void info_file(const std::string &arg)
bool inhibit_startup_message(void) const
void exec_path(const std::string &arg)
bool echo_commands(void) const
std::string m_docstrings_file
bool read_init_files(void) const
void no_window_system(bool arg)
octave_value & operator=(const octave_value &a)
octave_value arg(void) const
OCTAVE_BEGIN_NAMESPACE(octave) static octave_value daspk_fcn