36#include <xbps/xbps_object.h>
38typedef struct _prop_array *xbps_array_t;
44xbps_array_t xbps_array_create(
void);
45xbps_array_t xbps_array_create_with_capacity(
unsigned int);
47xbps_array_t xbps_array_copy(xbps_array_t);
48xbps_array_t xbps_array_copy_mutable(xbps_array_t);
50unsigned int xbps_array_capacity(xbps_array_t);
51unsigned int xbps_array_count(xbps_array_t);
52bool xbps_array_ensure_capacity(xbps_array_t,
unsigned int);
54void xbps_array_make_immutable(xbps_array_t);
55bool xbps_array_mutable(xbps_array_t);
57xbps_object_iterator_t xbps_array_iterator(xbps_array_t);
59xbps_object_t xbps_array_get(xbps_array_t,
unsigned int);
60bool xbps_array_set(xbps_array_t,
unsigned int, xbps_object_t);
61bool xbps_array_add(xbps_array_t, xbps_object_t);
62bool xbps_array_add_first(xbps_array_t, xbps_object_t);
63void xbps_array_remove(xbps_array_t,
unsigned int);
65bool xbps_array_equals(xbps_array_t, xbps_array_t);
67char * xbps_array_externalize(xbps_array_t);
68xbps_array_t xbps_array_internalize(
const char *);
70bool xbps_array_externalize_to_file(xbps_array_t,
const char *);
71bool xbps_array_externalize_to_zfile(xbps_array_t,
const char *);
72xbps_array_t xbps_array_internalize_from_file(
const char *);
73xbps_array_t xbps_array_internalize_from_zfile(
const char *);
79bool xbps_array_get_bool(xbps_array_t,
unsigned int,
81bool xbps_array_set_bool(xbps_array_t,
unsigned int,
84bool xbps_array_get_int8(xbps_array_t,
unsigned int,
86bool xbps_array_get_uint8(xbps_array_t,
unsigned int,
88bool xbps_array_set_int8(xbps_array_t,
unsigned int,
90bool xbps_array_set_uint8(xbps_array_t,
unsigned int,
93bool xbps_array_get_int16(xbps_array_t,
unsigned int,
95bool xbps_array_get_uint16(xbps_array_t,
unsigned int,
97bool xbps_array_set_int16(xbps_array_t,
unsigned int,
99bool xbps_array_set_uint16(xbps_array_t,
unsigned int,
102bool xbps_array_get_int32(xbps_array_t,
unsigned int,
104bool xbps_array_get_uint32(xbps_array_t,
unsigned int,
106bool xbps_array_set_int32(xbps_array_t,
unsigned int,
108bool xbps_array_set_uint32(xbps_array_t,
unsigned int,
111bool xbps_array_get_int64(xbps_array_t,
unsigned int,
113bool xbps_array_get_uint64(xbps_array_t,
unsigned int,
115bool xbps_array_set_int64(xbps_array_t,
unsigned int,
117bool xbps_array_set_uint64(xbps_array_t,
unsigned int,
120bool xbps_array_add_int8(xbps_array_t, int8_t);
121bool xbps_array_add_uint8(xbps_array_t, uint8_t);
123bool xbps_array_add_int16(xbps_array_t, int16_t);
124bool xbps_array_add_uint16(xbps_array_t, uint16_t);
126bool xbps_array_add_int32(xbps_array_t, int32_t);
127bool xbps_array_add_uint32(xbps_array_t, uint32_t);
129bool xbps_array_add_int64(xbps_array_t, int64_t);
130bool xbps_array_add_uint64(xbps_array_t, uint64_t);
132bool xbps_array_get_cstring(xbps_array_t,
unsigned int,
134bool xbps_array_set_cstring(xbps_array_t,
unsigned int,
136bool xbps_array_add_cstring(xbps_array_t,
const char *);
137bool xbps_array_add_cstring_nocopy(xbps_array_t,
139bool xbps_array_get_cstring_nocopy(xbps_array_t,
142bool xbps_array_set_cstring_nocopy(xbps_array_t,
145bool xbps_array_add_and_rel(xbps_array_t, xbps_object_t);