X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=src%2Finclude%2Fcore%2Fstore.h;h=308523a4476a1b861ad134e43815d7372088b036;hb=873812bad1b030d79da6402ed6d26d008179592d;hp=a9788f44bb5b59ac7b166b46667bdb0acc9a70f1;hpb=0e369b5129e64580e444e7d7ef4033a9d2995a28;p=sysdb.git diff --git a/src/include/core/store.h b/src/include/core/store.h index a9788f4..308523a 100644 --- a/src/include/core/store.h +++ b/src/include/core/store.h @@ -405,26 +405,32 @@ enum { /* * sdb_store_tojson: * Serialize the entire store to JSON and append the result to the specified - * buffer. + * buffer. If specified, only objects matching the filter will be included in + * the result (see sdb_store_host_tojson for details). * * Returns: * - 0 on success * - a negative value on error */ int -sdb_store_tojson(sdb_strbuf_t *buf, int flags); +sdb_store_tojson(sdb_strbuf_t *buf, sdb_store_matcher_t *filter, int flags); /* * sdb_store_host_tojson: * Serialize a host object to JSON and append the result to the specified - * buffer. + * buffer. If specified, only objects matching the filter will be included in + * the result. The filter is applied to each object individually and, thus, + * should not be of any object-type specific kind. The filter is never applied + * to the specified host object; the caller is responsible for this and for + * correctly handling skipped hosts. * * Returns: * - 0 on success * - a negative value on error */ int -sdb_store_host_tojson(sdb_store_obj_t *host, sdb_strbuf_t *buf, int flags); +sdb_store_host_tojson(sdb_store_obj_t *host, sdb_strbuf_t *buf, + sdb_store_matcher_t *filter, int flags); /* * sdb_store_iter_cb: