Synchronous API functions that do not use callbacks

Functions

getdns_return_t getdns_general_sync (getdns_context *context, const char *name, uint16_t request_type, getdns_dict *extensions, getdns_dict **response)
 
getdns_return_t getdns_address_sync (getdns_context *context, const char *name, getdns_dict *extensions, getdns_dict **response)
 
getdns_return_t getdns_hostname_sync (getdns_context *context, getdns_dict *address, getdns_dict *extensions, getdns_dict **response)
 
getdns_return_t getdns_service_sync (getdns_context *context, const char *name, getdns_dict *extensions, getdns_dict **response)
 

Detailed Description

Function Documentation

getdns_return_t getdns_general_sync ( getdns_context context,
const char *  name,
uint16_t  request_type,
getdns_dict extensions,
getdns_dict **  response 
)

These functions do not use callbacks, when the application calls one of these functions the library retrieves all of the data before returning. Return values are exactly the same as if you had used a callback with the asynchronous functions. retrieve general DNS data

Parameters
contextpointer to a previously created context to be used for this call
namethe ASCII based domain name to lookup
request_typeRR type for the query, e.g. GETDNS_RR_TYPE_NS
extensionsdict data structures, NULL to use no extensions
responseresponse
Returns
GETDNS_RETURN_GOOD on success
getdns_return_t getdns_address_sync ( getdns_context context,
const char *  name,
getdns_dict extensions,
getdns_dict **  response 
)

retrieve address assigned to a DNS name

Parameters
contextpointer to a previously created context to be used for this call
namethe ASCII based domain name to lookup
extensionsdict data structures, NULL to use no extensions
responseresponse
Returns
GETDNS_RETURN_GOOD on success
getdns_return_t getdns_hostname_sync ( getdns_context context,
getdns_dict address,
getdns_dict extensions,
getdns_dict **  response 
)

retrieve hostname assigned to an IP address

Parameters
contextpointer to a previously created context to be used for this call
addressthe address to look up
extensionsdict data structures, NULL to use no extensions
responseresponse
Returns
GETDNS_RETURN_GOOD on success
getdns_return_t getdns_service_sync ( getdns_context context,
const char *  name,
getdns_dict extensions,
getdns_dict **  response 
)

retrieve a service assigned to a DNS name

Parameters
contextpointer to a previously created context to be used for this call
namethe ASCII based domain name to lookup
extensionsdict data structures, NULL to use no extensions
responseresponse
Returns
GETDNS_RETURN_GOOD on success