This namespace holds some classes for using the C readline library with C++. The idea is to use STL containers and standard strings rather thant C strings and arrays, so that the user may have the full power of C++ available. However, this does create a bit of overhead, as we sometimes have to allocate and deallocate memory as we go from C arrays to STL containers and back. This has of course been kept to a minimum to the authors ability. The author believes that the overhead is a small price to pay for the increased ease of use due to the STL containers and like. As far as possible, the readline have been kept as coheriant as possible, but a few odd things does pop up from time to time.
|
Classes |
struct | basic_buffer |
| Buffer readline class. More...
|
struct | basic_callback |
| Readline in call-back mode. More...
|
struct | command |
| Command. More...
|
struct | basic_completion |
| Class to do completions for readline. More...
|
struct | basic_function_map |
| Map of currently defined functions. More...
|
struct | basic_history |
| history for readline. More...
|
struct | basic_key_map |
| key_map. More...
|
struct | basic_readline |
| Readline. More...
|
struct | basic_signal_handler |
| signal handler utility class
Signal handling for readline. More...
|
struct | basic_streambuf |
| Stream buffer reading from readline. More...
|
struct | basic_terminal |
| Terminal handling. More...
|
struct | undo |
| Utility class. More...
|
struct | single_thread |
| Default locking - for single threaded applications. More...
|
struct | guard |
| Utility class to lock a lock in a scope, and unlock it at axit of a scope. More...
|
struct | one_at_a_time |
| Utility class for common behaviour. More...
|
struct | singleton |
| Utility class to implement singletons. More...
|
Typedefs |
typedef basic_buffer< single_thread > | buffer |
typedef basic_callback< single_thread > | callback |
typedef int(* | command_t )(int, int) |
typedef basic_completion<
single_thread > | completion |
typedef basic_function_map<
single_thread > | function_map |
typedef basic_history< single_thread > | history |
typedef basic_key_map< single_thread > | key_map |
typedef basic_readline< single_thread > | readline |
typedef basic_signal_handler<
single_thread > | signal_handler |
typedef basic_streambuf< single_thread > | streambuf |
typedef basic_terminal< single_thread > | terminal |
Functions |
template<typename Lock> |
void | rlmm_callback (char *line) |
template<class T> |
int | rlmm_command_wrapper (int count, int key) |
template<typename Lock> |
char * | rlmm_completer (const char *what, int state) |
template<typename Lock> |
char ** | rlmm_alternate_completer (const char *what, int start, int end) |
template<typename Lock> |
char * | rlmm_filename_quote (char *what, int match, char *quote) |
template<typename Lock> |
char * | rlmm_filename_dequote (char *what, int quote) |
template<typename Lock> |
int | rlmm_quoted (char *what, int index) |
template<typename Lock> |
int | rlmm_remove (char **matches) |
template<typename Lock> |
int | rlmm_directory_hook (char **fullpath) |
template<typename Lock> |
void | rlmm_display_hook (char **matches, int n, int w) |
template<typename Lock> |
char * | rlmm_completer (const char *what, int state) |
template<typename Lock> |
char ** | rlmm_alternate_completer (const char *what, int start, int end) |
template<typename Lock> |
char * | rlmm_filename_quote (char *what, int match, char *quote) |
template<typename Lock> |
char * | rlmm_filename_dequote (char *what, int quote) |
template<typename Lock> |
int | rlmm_quoted (char *what, int index) |
template<typename Lock> |
int | rlmm_remove (char **matches) |
template<typename Lock> |
int | rlmm_directory_hook (char **fullpath) |
template<typename Lock> |
void | rlmm_display_hook (char **matches, int n, int w) |
template<typename Lock> |
int | rlmm_inhibit_expansion (char *line, int where) |
template<typename Lock> |
int | rlmm_inhibit_expansion (char *line, int where) |
template<typename Lock> |
int | rlmm_input_hook () |
template<typename Lock> |
int | rlmm_event_hook () |
template<typename Lock> |
int | rlmm_startup_hook () |
template<typename Lock> |
int | rlmm_read_character (FILE *in) |
template<typename Lock> |
void | rlmm_redisplay () |
template<typename Lock> |
void | rlmm_prepare (int eightbit) |
template<typename Lock> |
void | rlmm_deprepare () |
template<typename Lock> |
int | rlmm_read_character (FILE *in) |
template<typename Lock> |
void | rlmm_redisplay () |
template<typename Lock> |
void | rlmm_prepare (int eightbit) |
template<typename Lock> |
void | rlmm_deprepare () |
char * | rlmm_string_duplicate (const std::string &orig) |
char | rlmm_directory_separator () |
template<typename Lock> |
char * | rlmm_basename (const char *name) |
template<typename Lock> |
char * | rlmm_dirname (const char *name) |