libsrsirc  0.0.14
Lightweight, cross-platform IRC library
Macros | Typedefs
defs.h File Reference
#include <stdbool.h>
#include <stddef.h>
#include <stdint.h>

Go to the source code of this file.

Macros

#define DEF_HOST   "localhost"
 Default server to connect to (cf. irc_set_server())
 
#define DEF_PORT_PLAIN   ((uint16_t)6667)
 Default TCP port for plaintext IRC (cf. irc_set_server())
 
#define DEF_PORT_SSL   ((uint16_t)6697)
 Default TCP port for SSL IRC (cf. irc_set_server(), irc_set_ssl())
 
#define DEF_NICK   "srsirc"
 Default nickname (cf. irc_set_nick())
 
#define DEF_UNAME   "bsnsirc"
 Default IRC user name (cf. irc_set_uname())
 
#define DEF_FNAME   "serious business irc"
 Default IRC full name (cf. irc_set_fname())
 
#define DEF_CONFLAGS   0
 Default USER message flags (cf. irc_set_conflags())
 
#define DEF_SERV_DIST   "*"
 Default distribution for service logon (cf. irc_set_service_dist())
 
#define DEF_SERV_TYPE   0
 Default type string for service logon (cf. irc_set_service_type())
 
#define DEF_SERV_INFO   "srsbsns srvc"
 Default info string for service logon (cf. irc_set_service_info())
 
#define DEF_HCTO_US   120000000ul
 Default hard connect timeout in microsecs (cf. irc_set_connect_timeout())
 
#define DEF_SCTO_US   15000000ul
 Default soft connect timeout in microsecs (cf. irc_set_connect_timeout())
 
#define CMAP_RFC1459   0
 RFC1459 case mapping as per the 005 ISUPPORT spec. More...
 
#define CMAP_STRICT_RFC1459   1
 Strict RFC1459 case mapping as per the 005 ISUPPORT spec. More...
 
#define CMAP_ASCII   2
 ASCII case mapping as per the 005 ISUPPORT spec. More...
 
#define IRCPX_HTTP   0
 HTTP proxy type (cf. irc_set_proxy())
 
#define IRCPX_SOCKS4   1 /* NOT socks4a */
 Socks4 proxy type (cf. irc_set_proxy())
 
#define IRCPX_SOCKS5   2
 Socks5 proxy type (cf. irc_set_proxy())
 
#define CHANMODE_CLASS_A   1
 Channel mode classes as per the 005 ISUPPORT spec. (A) More...
 
#define CHANMODE_CLASS_B   2
 Channel mode classes as per the 005 ISUPPORT spec. (B) More...
 
#define CHANMODE_CLASS_C   3
 Channel mode classes as per the 005 ISUPPORT spec. (C) More...
 
#define CHANMODE_CLASS_D   4
 Channel mode classes as per the 005 ISUPPORT spec. (D) More...
 

Typedefs

typedef struct irc_s irc
 IRC context; pointers to this are our IRC context handle type. More...
 
typedef char * tokarr[18]
 Field array for the parts of incoming IRC protocol messages. More...
 
typedef bool(* fp_con_read) (tokarr *msg, void *tag)
 Logon-time callback for incoming protocol messages. More...
 
typedef void(* fp_mut_nick) (char *nick, size_t nick_sz)
 Logon-time callback type for nickname problems. More...
 
typedef bool(* uhnd_fn) (irc *ctx, tokarr *msg, size_t nargs, bool pre)
 User-registered protocol command callback type. More...