Concord - C Discord API library
A Discord API wrapper library written in C
|
Generic request dispatcher. More...
#include <discord-internal.h>
Data Fields | |
DISCORD_RET_DEFAULT_FIELDS | |
bool | has_type |
union { | |
void(* typed )(struct discord *client, struct discord_response *resp, const void *ret) | |
void(* typeless )(struct discord *client, struct discord_response *resp) | |
} | done |
void * | sync |
Generic request dispatcher.
discord_ret_dispatch::DISCORD_RET_DEFAULT_FIELDS |
bool discord_ret_dispatch::has_type |
true
if may receive a datatype from response
void(* discord_ret_dispatch::typed) (struct discord *client, struct discord_response *resp, const void *ret) |
void(* discord_ret_dispatch::typeless) (struct discord *client, struct discord_response *resp) |
union { ... } discord_ret_dispatch::done |
optional callback to be executed on a successful request
void* discord_ret_dispatch::sync |
if an address is provided, then request will block the thread and perform on-spot. On success the response object will be written to the address.