Changeset View
Changeset View
Standalone View
Standalone View
lib/libnv/dnv.h
Show All 39 Lines | |||||
#ifndef _NVLIST_T_DECLARED | #ifndef _NVLIST_T_DECLARED | ||||
#define _NVLIST_T_DECLARED | #define _NVLIST_T_DECLARED | ||||
struct nvlist; | struct nvlist; | ||||
typedef struct nvlist nvlist_t; | typedef struct nvlist nvlist_t; | ||||
#endif | #endif | ||||
__BEGIN_DECLS | |||||
/* | /* | ||||
* The dnvlist_get functions returns value associated with the given name. | * The dnvlist_get functions returns value associated with the given name. | ||||
* If it returns a pointer, the pointer represents internal buffer and should | * If it returns a pointer, the pointer represents internal buffer and should | ||||
* not be freed by the caller. | * not be freed by the caller. | ||||
* If no element of the given name and type exists, the function will return | * If no element of the given name and type exists, the function will return | ||||
* provided default value. | * provided default value. | ||||
*/ | */ | ||||
▲ Show 20 Lines • Show All 41 Lines • ▼ Show 20 Lines | |||||
void *dnvlist_takef_binary(nvlist_t *nvl, size_t *sizep, void *defval, size_t defsize, const char *namefmt, ...) __printflike(5, 6); | void *dnvlist_takef_binary(nvlist_t *nvl, size_t *sizep, void *defval, size_t defsize, const char *namefmt, ...) __printflike(5, 6); | ||||
bool dnvlist_takev_bool(nvlist_t *nvl, bool defval, const char *namefmt, va_list nameap) __printflike(3, 0); | bool dnvlist_takev_bool(nvlist_t *nvl, bool defval, const char *namefmt, va_list nameap) __printflike(3, 0); | ||||
uint64_t dnvlist_takev_number(nvlist_t *nvl, uint64_t defval, const char *namefmt, va_list nameap) __printflike(3, 0); | uint64_t dnvlist_takev_number(nvlist_t *nvl, uint64_t defval, const char *namefmt, va_list nameap) __printflike(3, 0); | ||||
char *dnvlist_takev_string(nvlist_t *nvl, char *defval, const char *namefmt, va_list nameap) __printflike(3, 0); | char *dnvlist_takev_string(nvlist_t *nvl, char *defval, const char *namefmt, va_list nameap) __printflike(3, 0); | ||||
nvlist_t *dnvlist_takev_nvlist(nvlist_t *nvl, nvlist_t *defval, const char *namefmt, va_list nameap) __printflike(3, 0); | nvlist_t *dnvlist_takev_nvlist(nvlist_t *nvl, nvlist_t *defval, const char *namefmt, va_list nameap) __printflike(3, 0); | ||||
int dnvlist_takev_descriptor(nvlist_t *nvl, int defval, const char *namefmt, va_list nameap) __printflike(3, 0); | int dnvlist_takev_descriptor(nvlist_t *nvl, int defval, const char *namefmt, va_list nameap) __printflike(3, 0); | ||||
void *dnvlist_takev_binary(nvlist_t *nvl, size_t *sizep, void *defval, size_t defsize, const char *namefmt, va_list nameap) __printflike(5, 0); | void *dnvlist_takev_binary(nvlist_t *nvl, size_t *sizep, void *defval, size_t defsize, const char *namefmt, va_list nameap) __printflike(5, 0); | ||||
__END_DECLS | |||||
#endif /* !_DNV_H_ */ | #endif /* !_DNV_H_ */ |