26 #if ! defined (octave_defun_int_h)
27 #define octave_defun_int_h 1
29 #include "octave-config.h"
45 extern OCTINTERP_API
void print_usage (
const std::string&);
47 extern OCTINTERP_API
void check_version (
const std::string& version,
48 const std::string& fcn);
50 extern OCTINTERP_API
void
53 bool relative =
false);
55 extern OCTINTERP_API
void
58 bool relative =
false);
60 extern OCTINTERP_API
void
90 const octave::dynamic_library& shl,
91 const std::string& doc,
bool relative =
false)
98 const octave::dynamic_library& shl,
99 const std::string& doc,
bool relative =
false)
106 const octave::dynamic_library& shl,
107 bool relative =
false)
118 #define FORWARD_DECLARE_FUNX(name) \
119 extern OCTAVE_EXPORT octave_value_list \
120 name (const octave_value_list&, int)
122 #define FORWARD_DECLARE_METHODX(name) \
123 extern OCTAVE_EXPORT octave_value_list \
124 name (octave::interpreter&, const octave_value_list&, int)
126 #define FORWARD_DECLARE_FUN(name) \
127 FORWARD_DECLARE_FUNX (F ## name)
129 #define FORWARD_DECLARE_METHOD(name) \
130 FORWARD_DECLARE_METHODX (F ## name)
132 #define DECLARE_FUNX(name, args_name, nargout_name) \
133 OCTAVE_EXPORT octave_value_list \
134 name (const octave_value_list& args_name, int nargout_name)
136 #define DECLARE_METHODX(name, interp_name, args_name, nargout_name) \
137 OCTAVE_EXPORT octave_value_list \
138 name (octave::interpreter& interp_name, \
139 const octave_value_list& args_name, int nargout_name)
141 #define DECLARE_FUN(name, args_name, nargout_name) \
142 DECLARE_FUNX (F ## name, args_name, nargout_name)
144 #define DECLARE_METHOD(name, interp_name, args_name, nargout_name) \
145 DECLARE_METHODX (F ## name, interp_name, args_name, nargout_name)
147 #define FORWARD_DECLARE_STATIC_FUNX(name) \
148 static octave_value_list \
149 name (const octave_value_list&, int)
151 #define FORWARD_DECLARE_STATIC_METHODX(name) \
152 static octave_value_list \
153 name (octave::interpreter&, const octave_value_list&, int)
155 #define FORWARD_DECLARE_STATIC_FUN(name) \
156 FORWARD_DECLARE_STATIC_FUNX (F ## name)
158 #define FORWARD_DECLARE_STATIC_METHOD(name) \
159 FORWARD_DECLARE_STATIC_METHODX (F ## name)
161 #define DECLARE_STATIC_FUNX(name, args_name, nargout_name) \
162 static octave_value_list \
163 name (const octave_value_list& args_name, int nargout_name)
165 #define DECLARE_STATIC_METHODX(name, interp_name, args_name, nargout_name) \
166 static octave_value_list \
167 name (octave::interpreter& interp_name, \
168 const octave_value_list& args_name, int nargout_name)
170 #define DECLARE_STATIC_FUN(name, args_name, nargout_name) \
171 DECLARE_STATIC_FUNX (F ## name, args_name, nargout_name)
173 #define DECLARE_STATIC_METHOD(name, interp_name, args_name, nargout_name) \
174 DECLARE_STATIC_METHODX (F ## name, interp_name, args_name, nargout_name)
183 (*octave_dld_fcn_getter) (
const octave::dynamic_library&,
bool relative);
185 #if defined (OCTAVE_SOURCE)
186 # define DEFINE_FUN_INSTALLER_FUN(name, doc) \
187 DEFINE_FUNX_INSTALLER_FUN(#name, F ## name, G ## name, "external-doc")
189 # define DEFINE_FUN_INSTALLER_FUN(name, doc) \
190 DEFINE_FUNX_INSTALLER_FUN(#name, F ## name, G ## name, doc)
193 #define DEFINE_FUNX_INSTALLER_FUN(name, fname, gname, doc) \
197 gname (const octave::dynamic_library& shl, bool relative) \
199 check_version (OCTAVE_API_VERSION, name); \
201 octave_dld_function *fcn \
202 = octave_dld_function::create (fname, shl, name, doc); \
205 fcn->mark_relative (); \
octave_value_list(* fcn)(const octave_value_list &, int)
octave_value_list(* meth)(octave::interpreter &, const octave_value_list &, int)
OCTAVE_BEGIN_NAMESPACE(octave) static octave_value daspk_fcn
OCTINTERP_API void install_dld_function(octave_dld_function::fcn f, const std::string &name, const dynamic_library &shl, const std::string &doc, bool relative=false)
bool(* octave_dld_fcn_installer)(const octave::dynamic_library &, bool relative)
OCTINTERP_API void print_usage(void)
OCTINTERP_API void check_version(const std::string &version, const std::string &fcn)
OCTINTERP_API void install_mex_function(void *fptr, bool fmex, const std::string &name, const dynamic_library &shl, bool relative=false)
OCTINTERP_API dynamic_library get_current_shlib(void)
F77_RET_T const F77_DBLE const F77_DBLE * f
FloatComplex(* fptr)(const FloatComplex &, float, int, octave_idx_type &)