#include "ks_config.h"
#include "ks_bquery.h"
#include "ks_malloc.h"
#include <stdio.h>
#include <string.h>
Go to the source code of this file.
Functions | |
| ks_type_t * | ks_bquery_type (void) |
| ks_bquery_t * | ks_bquery_new (void) |
| void | ks_bquery_free (ks_bquery_t *q) |
| void | ks_bquery_id_set (ks_bquery_t *q, const char *id, size_t len) |
| ks_string_t * | ks_bquery_id_get (ks_bquery_t *q) |
| void | ks_bquery_feed_add (ks_bquery_t *q, const char *id) |
| void | ks_bquery_composite_add (ks_bquery_t *q, const char *id) |
| void | ks_bquery_combiner_add (ks_bquery_t *q, const char *id) |
| void | ks_bquery_identity_add (ks_bquery_t *q, const char *id, int idt) |
| void | ks_bquery_identity_add_tagged (ks_bquery_t *q, const char *id, int idt, const char *tag) |
| void | ks_bquery_flags_set (ks_bquery_t *q, long flags) |
| ks_string_t * | ks_bquery_packet (ks_bquery_t *q) |
| int | ks_bquery_has_auth (ks_bquery_t *q) |
| void | ks_bquery_set_auth (ks_bquery_t *q, const char *p, const char *c) |
Definition in file ks_bquery.c.
|
||||||||||||
|
Add an additional combiner ito be queried to a ks_bquery_t.
Definition at line 260 of file ks_bquery.c. References _ks_bquery_t::combiners, ks_array_add(), and ks_string_new(). |
|
||||||||||||
|
Add a composite (aka feedset) to be queried to a ks_bquery_packet.
Definition at line 245 of file ks_bquery.c. References _ks_bquery_t::composites, ks_array_add(), and ks_string_new(). Referenced by main(). |
|
||||||||||||
|
Adds a feed to be queried to a ks_bquery_t.
Definition at line 229 of file ks_bquery.c. References _ks_bquery_t::feeds, ks_array_add(), and ks_string_new(). Referenced by main(). |
|
||||||||||||
|
Set the flags in a ks_bquery_t.
Definition at line 355 of file ks_bquery.c. References _ks_bquery_t::flags, and ks_number_set(). Referenced by main(). |
|
|
Destroys a ks_bquery_t, freeing all memory that has been allocated for it.
Definition at line 159 of file ks_bquery.c. References _ks_bquery_t::combiners, _ks_bquery_t::composites, _ks_bquery_t::credentials, _ks_bquery_t::feeds, _ks_bquery_t::flags, _ks_bquery_t::id, _ks_bquery_t::identities, ks_array_fini(), ks_free(), ks_number_fini(), ks_string_free(), and _ks_bquery_t::principal. Referenced by main(). |
|
|
Determine whether or not a ks_bquery_t has authentication tokens.
Definition at line 386 of file ks_bquery.c. References _ks_bquery_t::principal. Referenced by ks_socket_send(). |
|
|
Returns the cookie value from a ks_bquery_t. If the ks_bquery_t does not already have an ID, one is generated and stored within it. libkarmaclient does not generate bquery packets that do not have cookies.
Definition at line 210 of file ks_bquery.c. References _ks_bquery_t::id, and ks_string_new(). Referenced by ks_socket_ask(). |
|
||||||||||||||||
|
Sets the value of the cookie for this query. This will be returned by the karmaserver in the response packet to allow the client to keep track of query/response pairs.
Definition at line 189 of file ks_bquery.c. References _ks_bquery_t::id, ks_string_new(), and ks_string_set(). |
|
||||||||||||||||
|
Add an identity (on which an opinion is sought from a karmaserver) to a ks_bquery_t. To pass additional context information about the identity, use ks_bquery_identity_add_tagged.
Definition at line 314 of file ks_bquery.c. |
|
||||||||||||||||||||
|
Add an identity (on which an opinion is sought from a karmaserver) and a tag string to a ks_bquery_t.
Definition at line 338 of file ks_bquery.c. References ks_array_add(), and ks_string_new(). |
|
|
Constructs a new ks_bquery_t. This function allocates memory that must be freed by ks_bquery_free().
Definition at line 135 of file ks_bquery.c. References _ks_bquery_t::base, _ks_bquery_t::combiners, _ks_bquery_t::composites, _ks_bquery_t::credentials, _ks_bquery_t::feeds, _ks_bquery_t::flags, _ks_bquery_t::id, _ks_bquery_t::identities, ks_array_init(), ks_malloc(), ks_number_init(), _ks_bquery_t::principal, and _ks_base_t::type. Referenced by main(). |
|
|
Convert a ks_bquery_t object into a bquery packet.
Definition at line 370 of file ks_bquery.c. References ks_string_new(). Referenced by ks_socket_send(). |
|
||||||||||||||||
|
Set authentication tokens for a bquery object.
Definition at line 407 of file ks_bquery.c. References _ks_bquery_t::credentials, ks_string_free(), ks_string_new(), ks_string_set(), and _ks_bquery_t::principal. Referenced by ks_socket_send(). |
|
|
Returns the metaclass for ks_bquery_t objects.
Definition at line 120 of file ks_bquery.c. |
1.4.4