#include "el.h"
Go to the source code of this file.
Classes | |
struct | ElBuiltin_t |
Defines | |
#define | _el_builtins_h_included 1 |
Functions | |
void | el_register_function (const char *name, ElBuiltin_t::handler_func f, const char *help=NULL) |
int | el_func_show_function_list (EditLine_t *el, int, const char **) |
int | el_func_readline_reinit (EditLine_t *, int, const char **) |
ElBuiltin_t ** | el_builtins_list (int *count) |
ElBuiltin_t * | el_builtin_by_name (const char *) |
#define _el_builtins_h_included 1 |
Definition at line 5 of file builtins.h.
ElBuiltin_t* el_builtin_by_name | ( | const char * | ) |
Returns the builtin function for the given name, or NULL if none is found. The client may modify the function, but should not delete it
(added by stephan)
Definition at line 109 of file builtins.cxx.
References el_internal_builtins(), and NULL.
Referenced by el_parse().
ElBuiltin_t** el_builtins_list | ( | int * | count | ) |
Returns an array of ElBuiltin_t objects. The caller does NOT own it - it is a shared list. The list may become invalided upon later registration of functions, so don't hold on to it.
The variable count is set to the number of items in the returned list.
(added by stephan)
Definition at line 58 of file builtins.cxx.
References el_builtins_vec, and el_internal_builtins().
int el_func_readline_reinit | ( | EditLine_t * | el, | |
int | , | |||
const char ** | ||||
) |
Calls rl_initialize(), to reset the internal EditLine_t to a sane state.
Definition at line 78 of file builtins.cxx.
References EditLine_t::fOutFile, fprintf(), and rl_initialize().
Referenced by el_builtins_init().
int el_func_show_function_list | ( | EditLine_t * | el, | |
int | , | |||
const char ** | ||||
) |
Shows list of built-in functions via el->fOutFile.
Definition at line 90 of file builtins.cxx.
References el_internal_builtins(), ElBuiltin_t::fHelp, ElBuiltin_t::fName, EditLine_t::fOutFile, fprintf(), and NULL.
Referenced by el_builtins_init().
void el_register_function | ( | const char * | name, | |
ElBuiltin_t::handler_func | f, | |||
const char * | help = NULL | |||
) |
Registers f as a built-in function handler.
(added by stephan)
Definition at line 51 of file builtins.cxx.
References el_internal_builtins().
Referenced by el_builtins_init().