2019-06-25 18:20:27 +02:00
|
|
|
#ifndef DC_GUILD_H
|
|
|
|
#define DC_GUILD_H
|
|
|
|
|
2019-07-19 20:52:12 +02:00
|
|
|
#include <dc/channel.h>
|
|
|
|
|
|
|
|
#include <jansson.h>
|
|
|
|
#include <stdint.h>
|
|
|
|
|
2019-06-25 18:20:27 +02:00
|
|
|
/* Discords version of groups or chat servers
|
|
|
|
*/
|
|
|
|
struct dc_guild_;
|
|
|
|
typedef struct dc_guild_ *dc_guild_t;
|
|
|
|
|
|
|
|
dc_guild_t dc_guild_new(void);
|
2019-07-19 20:52:12 +02:00
|
|
|
dc_guild_t dc_guild_from_json(json_t *j);
|
|
|
|
|
|
|
|
size_t dc_guild_channels(dc_guild_t d);
|
|
|
|
dc_channel_t dc_guild_nth_channel(dc_guild_t d, size_t idx);
|
2019-07-20 12:51:07 +02:00
|
|
|
dc_channel_t dc_guild_channel_by_name(dc_guild_t g, char const *name);
|
2019-06-25 18:20:27 +02:00
|
|
|
|
|
|
|
char const *dc_guild_name(dc_guild_t d);
|
|
|
|
void dc_guild_set_name(dc_guild_t d, char const *val);
|
|
|
|
|
|
|
|
char const *dc_guild_id(dc_guild_t d);
|
|
|
|
void dc_guild_set_id(dc_guild_t d, char const *val);
|
|
|
|
|
|
|
|
#endif
|