2005-09-15 09:58:31 -04:00
|
|
|
#ifndef EL__CONFIG_OPTTYPES_H
|
|
|
|
#define EL__CONFIG_OPTTYPES_H
|
|
|
|
|
|
|
|
#include "config/options.h"
|
|
|
|
#include "util/string.h"
|
|
|
|
|
|
|
|
struct option_type_info {
|
|
|
|
unsigned char *name;
|
|
|
|
unsigned char *(*cmdline)(struct option *, unsigned char ***, int *);
|
|
|
|
unsigned char *(*read)(struct option *, unsigned char **, int *);
|
2019-02-17 14:46:16 -05:00
|
|
|
void (*write)(struct option *, struct string_ *);
|
2007-08-28 13:11:52 -04:00
|
|
|
void (*dup)(struct option *, struct option *, int);
|
2005-09-15 09:58:31 -04:00
|
|
|
int (*set)(struct option *, unsigned char *);
|
2008-02-03 07:36:48 -05:00
|
|
|
int (*equals)(struct option *, const unsigned char *);
|
2005-09-15 09:58:31 -04:00
|
|
|
unsigned char *help_str;
|
|
|
|
};
|
|
|
|
|
|
|
|
/* enum option_type is index in this array */
|
|
|
|
extern const struct option_type_info option_types[];
|
|
|
|
|
|
|
|
extern int commandline;
|
|
|
|
|
|
|
|
unsigned char *get_option_type_name(enum option_type type);
|
|
|
|
|
|
|
|
#endif
|