libweed  0.6.0
 All Data Structures Files Functions Variables Typedefs Macros
Data Structures | Macros | Typedefs
weed.h File Reference
#include <stddef.h>
#include <inttypes.h>

Go to the source code of this file.

Data Structures

struct  weed_leaf_t
 
struct  weed_data_t
 

Macros

#define __need_size_t
 
#define __need_NULL
 
#define WEED_TRUE   1
 
#define WEED_FALSE   0
 
#define WEED_LEAF_READONLY_PLUGIN   (1<<0)
 
#define WEED_LEAF_READONLY_HOST   (1<<1)
 
#define WEED_NO_ERROR   0
 
#define WEED_ERROR_MEMORY_ALLOCATION   1
 
#define WEED_ERROR_LEAF_READONLY   2
 
#define WEED_ERROR_NOSUCH_ELEMENT   3
 
#define WEED_ERROR_NOSUCH_LEAF   4
 
#define WEED_ERROR_WRONG_SEED_TYPE   5
 
#define WEED_SEED_INT   1
 
#define WEED_SEED_DOUBLE   2
 
#define WEED_SEED_BOOLEAN   3
 
#define WEED_SEED_STRING   4
 
#define WEED_SEED_INT64   5
 
#define WEED_SEED_VOIDPTR   65
 
#define WEED_SEED_PLANTPTR   66
 
#define HAVE_WEED_PLANT_T
 

Typedefs

typedef void *(* weed_malloc_f )(size_t size)
 
typedef void(* weed_free_f )(void *ptr)
 
typedef void *(* weed_memset_f )(void *s, int c, size_t n)
 
typedef void *(* weed_memcpy_f )(void *dest, const void *src, size_t n)
 
typedef weed_leaf_t weed_plant_t
 
typedef size_t weed_size_t
 
typedef int64_t weed_timecode_t
 
typedef int(* weed_default_getter_f )(weed_plant_t *plant, const char *key, int idx, void *value)
 
typedef weed_plant_t *(* weed_plant_new_f )(int plant_type)
 
typedef char **(* weed_plant_list_leaves_f )(weed_plant_t *plant)
 
typedef int(* weed_leaf_set_f )(weed_plant_t *plant, const char *key, int seed_type, int num_elems, void *value)
 
typedef int(* weed_leaf_get_f )(weed_plant_t *plant, const char *key, int idx, void *value)
 
typedef int(* weed_leaf_num_elements_f )(weed_plant_t *plant, const char *key)
 
typedef size_t(* weed_leaf_element_size_f )(weed_plant_t *plant, const char *key, int idx)
 
typedef int(* weed_leaf_seed_type_f )(weed_plant_t *plant, const char *key)
 
typedef int(* weed_leaf_get_flags_f )(weed_plant_t *plant, const char *key)
 

Macro Definition Documentation

#define __need_NULL
#define __need_size_t
#define HAVE_WEED_PLANT_T
#define WEED_ERROR_LEAF_READONLY   2
#define WEED_ERROR_MEMORY_ALLOCATION   1
#define WEED_ERROR_NOSUCH_ELEMENT   3
#define WEED_ERROR_NOSUCH_LEAF   4
#define WEED_ERROR_WRONG_SEED_TYPE   5
#define WEED_FALSE   0
#define WEED_LEAF_READONLY_HOST   (1<<1)
#define WEED_LEAF_READONLY_PLUGIN   (1<<0)
#define WEED_NO_ERROR   0
#define WEED_SEED_BOOLEAN   3
#define WEED_SEED_DOUBLE   2
#define WEED_SEED_INT   1
#define WEED_SEED_INT64   5
#define WEED_SEED_PLANTPTR   66
#define WEED_SEED_STRING   4
#define WEED_SEED_VOIDPTR   65
#define WEED_TRUE   1

Typedef Documentation

typedef int(* weed_default_getter_f)(weed_plant_t *plant, const char *key, int idx, void *value)

this is fixed for ever, set in bootstrap_func

typedef void(* weed_free_f)(void *ptr)
typedef size_t(* weed_leaf_element_size_f)(weed_plant_t *plant, const char *key, int idx)
typedef int(* weed_leaf_get_f)(weed_plant_t *plant, const char *key, int idx, void *value)
typedef int(* weed_leaf_get_flags_f)(weed_plant_t *plant, const char *key)
typedef int(* weed_leaf_num_elements_f)(weed_plant_t *plant, const char *key)
typedef int(* weed_leaf_seed_type_f)(weed_plant_t *plant, const char *key)
typedef int(* weed_leaf_set_f)(weed_plant_t *plant, const char *key, int seed_type, int num_elems, void *value)
typedef void*(* weed_malloc_f)(size_t size)
typedef void*(* weed_memcpy_f)(void *dest, const void *src, size_t n)
typedef void*(* weed_memset_f)(void *s, int c, size_t n)
typedef char**(* weed_plant_list_leaves_f)(weed_plant_t *plant)
typedef weed_plant_t*(* weed_plant_new_f)(int plant_type)
typedef weed_leaf_t weed_plant_t
typedef size_t weed_size_t
typedef int64_t weed_timecode_t