iPXE
|
A setting type. More...
#include <settings.h>
Data Fields | |
const char * | name |
Name. More... | |
int(* | parse )(const struct setting_type *type, const char *value, void *buf, size_t len) |
Parse formatted string to setting value. More... | |
int(* | format )(const struct setting_type *type, const void *raw, size_t raw_len, char *buf, size_t len) |
Format setting value as a string. More... | |
int(* | denumerate )(const struct setting_type *type, unsigned long value, void *buf, size_t len) |
Convert number to setting value. More... | |
int(* | numerate )(const struct setting_type *type, const void *raw, size_t raw_len, unsigned long *value) |
Convert setting value to number. More... | |
A setting type.
This represents a type of setting (e.g. string, IPv4 address, etc.).
Definition at line 191 of file settings.h.
const char* setting_type::name |
Name.
This is the name exposed to the user (e.g. "string").
Definition at line 196 of file settings.h.
Referenced by setting_name().
int( * setting_type::parse) (const struct setting_type *type, const char *value, void *buf, size_t len) |
Parse formatted string to setting value.
type | Setting type |
value | Formatted setting value |
buf | Buffer to contain raw value |
len | Length of buffer |
len | Length of raw value, or negative error |
Definition at line 205 of file settings.h.
int( * setting_type::format) (const struct setting_type *type, const void *raw, size_t raw_len, char *buf, size_t len) |
Format setting value as a string.
type | Setting type |
raw | Raw setting value |
raw_len | Length of raw setting value |
buf | Buffer to contain formatted value |
len | Length of buffer |
len | Length of formatted value, or negative error |
Definition at line 216 of file settings.h.
int( * setting_type::denumerate) (const struct setting_type *type, unsigned long value, void *buf, size_t len) |
Convert number to setting value.
type | Setting type |
value | Numeric value |
buf | Buffer to contain raw value |
len | Length of buffer |
len | Length of raw value, or negative error |
Definition at line 226 of file settings.h.
int( * setting_type::numerate) (const struct setting_type *type, const void *raw, size_t raw_len, unsigned long *value) |
Convert setting value to number.
type | Setting type |
raw | Raw setting value |
raw_len | Length of raw setting value |
value | Numeric value to fill in |
rc | Return status code |
Definition at line 237 of file settings.h.
Referenced by acpi_settings_fetch().