Defines | Functions

sofia-sip/sresolv.h File Reference

Easy API for Sofia DNS Resolver. More...

#include <sofia-sip/su.h>
#include <sofia-sip/su_wait.h>
#include <sofia-sip/su_tag.h>
#include <sofia-resolv/sres.h>
#include <sofia-resolv/sres_record.h>
#include <sofia-resolv/sres_async.h>
Include dependency graph for sresolv.h:

Go to the source code of this file.

Defines

#define SRESOLV_H
 Defined when <sofia-sip/sresolv.h> has been included.
#define SRESOLVTAG_ANY()
 Filter tag matching any sresolv tag.
#define SRESTAG_RESOLV_CONF(x)
 Path of resolv.conf file.
#define SRESTAG_CACHE(x)
 Pointer to existing sres_cache_t object.

Functions

sres_resolver_tsres_resolver_create (su_root_t *root, char const *resolv_conf, tag_type_t, tag_value_t,...)
 Create a resolver object using root reactor.
int sres_resolver_destroy (sres_resolver_t *res)
 Destroy a resolver object.
su_socket_t sres_resolver_root_socket (sres_resolver_t *res)
 Return a socket registered to su_root_t object.

Detailed Description

Easy API for Sofia DNS Resolver.

Author:
Pekka Pessi <Pekka.Pessi@nokia-email.address.hidden>,
Teemu Jalava <Teemu.Jalava@nokia-email.address.hidden>,
Mikko Haataja <ext-Mikko.A.Haataja@nokia-email.address.hidden>.

Define Documentation

#define SRESOLV_H

Defined when <sofia-sip/sresolv.h> has been included.

#define SRESOLVTAG_ANY (  ) 

Filter tag matching any sresolv tag.

#define SRESTAG_CACHE (   x  ) 

Pointer to existing sres_cache_t object.

#define SRESTAG_RESOLV_CONF (   x  ) 

Path of resolv.conf file.


Function Documentation

sres_resolver_t* sres_resolver_create ( su_root_t root,
char const *  conf_file_path,
tag_type_t  tag,
tag_value_t  value,
  ... 
)

Create a resolver object using root reactor.

Create a resolver object using root reactor.

The function sres_resolver_create() is used to allocate and initialize the resolver object using the Sofia asynchronous reactor su_root_t.

int sres_resolver_destroy ( sres_resolver_t res  ) 

Destroy a resolver object.

su_socket_t sres_resolver_root_socket ( sres_resolver_t res  ) 

Return a socket registered to su_root_t object.

Return values:
sockfd if succesful
INVALID_SOCKET (-1) upon an error
Errors:
EFAULT Invalid argument passed.
EINVAL Resolver is not using su_root_t.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines

Sofia-SIP 1.12.11 - Copyright (C) 2006 Nokia Corporation. All rights reserved. Licensed under the terms of the GNU Lesser General Public License.