25 #define PRIVATE(a_obj) (a_obj)->priv 34 static CRPropList *cr_prop_list_allocate (
void);
42 cr_prop_list_allocate (
void)
81 g_return_val_if_fail (a_to_append, NULL);
90 g_return_val_if_fail (cur, NULL);
91 PRIVATE (cur)->next = a_to_append;
92 PRIVATE (a_to_append)->prev = cur;
115 g_return_val_if_fail (a_prop && a_decl, NULL);
117 list = cr_prop_list_allocate ();
118 g_return_val_if_fail (list &&
PRIVATE (list), NULL);
140 g_return_val_if_fail (a_to_prepend, NULL);
145 for (cur = a_to_prepend; cur &&
PRIVATE (cur)->next;
147 g_return_val_if_fail (cur, NULL);
170 g_return_val_if_fail (a_this &&
PRIVATE (a_this)
171 && a_prop_name && a_decl, NULL);
173 list = cr_prop_list_allocate ();
174 g_return_val_if_fail (list, NULL);
175 PRIVATE (list)->prop = a_prop_name;
191 g_return_val_if_fail (a_this &&
PRIVATE (a_this)
194 PRIVATE (a_this)->prop = a_prop;
212 g_return_val_if_fail (a_this &&
PRIVATE (a_this)
215 *a_prop =
PRIVATE (a_this)->prop;
229 g_return_val_if_fail (a_this &&
PRIVATE (a_this)
232 PRIVATE (a_this)->decl = a_decl;
246 g_return_val_if_fail (a_this &&
PRIVATE (a_this)
249 *a_decl =
PRIVATE (a_this)->decl;
279 for (cur = a_this; cur; cur =
PRIVATE (cur)->next) {
282 &&
PRIVATE (cur)->prop->stryng->str
284 && a_prop->stryng->str
285 && !strcmp (
PRIVATE (cur)->prop->stryng->str,
286 a_prop->stryng->str))
310 g_return_val_if_fail (a_this &&
PRIVATE (a_this), NULL);
327 g_return_val_if_fail (a_this &&
PRIVATE (a_this), NULL);
347 g_return_val_if_fail (a_this &&
PRIVATE (a_this) && a_pair, NULL);
352 g_return_val_if_fail (
PRIVATE (next), NULL);
353 g_return_val_if_fail (
PRIVATE (next)->prev == a_pair, NULL);
357 g_return_val_if_fail (
PRIVATE (prev), NULL);
358 g_return_val_if_fail (
PRIVATE (prev)->next == a_pair, NULL);
367 if (a_this == a_pair) {
385 g_return_if_fail (a_this &&
PRIVATE (a_this));
390 g_return_if_fail (tail);
CRPropList * cr_prop_list_append2(CRPropList *a_this, CRString *a_prop, CRDeclaration *a_decl)
cr_prop_list_append2: Appends a pair of prop/declaration to the current prop list.
CRPropList * cr_prop_list_prepend2(CRPropList *a_this, CRString *a_prop_name, CRDeclaration *a_decl)
cr_prop_list_prepend2: @a_this: the current instance of CRPropList @a_prop_name: property name to app...
enum CRStatus cr_prop_list_set_prop(CRPropList *a_this, CRString *a_prop)
cr_prop_list_set_prop: @a_this: the current instance of CRPropList @a_prop: the property to set
enum CRStatus cr_prop_list_lookup_prop(CRPropList *a_this, CRString *a_prop, CRPropList **a_pair)
cr_prop_list_lookup_prop: @a_this: the current instance of CRPropList @a_prop: the property to lookup...
CRStatus
The status type returned by the methods of the croco library.
typedefG_BEGIN_DECLS struct _CRPropList CRPropList
void cr_prop_list_destroy(CRPropList *a_this)
cr_prop_list_destroy: @a_this: the current instance of CRPropList
CRPropList * cr_prop_list_get_next(CRPropList *a_this)
cr_prop_list_get_next: @a_this: the current instance of CRPropList
CRPropList * cr_prop_list_unlink(CRPropList *a_this, CRPropList *a_pair)
cr_prop_list_unlink: @a_this: the current list of prop/decl pairs @a_pair: the prop/decl pair to unli...
typedefG_BEGIN_DECLS struct _CRString CRString
CRPropList * cr_prop_list_append(CRPropList *a_this, CRPropList *a_to_append)
cr_prop_list_append: @a_this: the current instance of CRPropList @a_to_append: the property list to a...
CRPropList * cr_prop_list_get_prev(CRPropList *a_this)
cr_prop_list_get_prev: @a_this: the current instance of CRPropList
enum CRStatus cr_prop_list_get_decl(CRPropList const *a_this, CRDeclaration **a_decl)
cr_prop_list_get_decl: @a_this: the current instance of CRPropList @a_decl: out parameter.
enum CRStatus cr_prop_list_get_prop(CRPropList const *a_this, CRString **a_prop)
cr_prop_list_get_prop: @a_this: the current instance of CRPropList @a_prop: out parameter.
CRPropList * cr_prop_list_prepend(CRPropList *a_this, CRPropList *a_to_prepend)
cr_prop_list_prepend: @a_this: the current instance of CRPropList @a_to_prepend: the new list to prep...
enum CRStatus cr_prop_list_set_decl(CRPropList *a_this, CRDeclaration *a_decl)
cr_prop_list_set_decl: @a_this: the current instance of CRPropList @a_decl: the new property value.
#define cr_utils_trace_info(a_msg)
Traces an info message.