You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
sems/core/plug-in/sipctrl/resolver.h

48 lines
601 B

#ifndef _resolver_h_
#define _resolver_h_
struct sockaddr_storage;
/* struct name_entry */
/* { */
/* string name; */
/* string address; */
/* }; */
enum address_type {
IPv4=1,
IPv6=2
};
enum proto_type {
TCP=1,
UDP=2
};
class resolver
{
static resolver* _instance;
resolver();
~resolver();
public:
static resolver* instance();
int resolve_name(const char* name, sockaddr_storage* sa,
const address_type types, const proto_type protos);
};
#endif
/** EMACS **
* Local variables:
* mode: c++
* c-basic-offset: 4
* End:
*/