#include <DnsResult.hxx>
Definition at line 65 of file DnsResult.hxx.
◆ DataVector
◆ Type
| Enumerator |
|---|
| Available | |
| Pending | |
| Finished | |
| Destroyed | |
Definition at line 72 of file DnsResult.hxx.
◆ DnsResult()
◆ ~DnsResult()
| DnsResult::~DnsResult |
( |
| ) |
|
|
virtual |
◆ available()
Tries to load the next tuple. If Available is returned, the tuple may be accessed using current(). Safe to call after DnsHandler::handle callback has been called.
- Returns
- Available if there is a result ready, Pending if it needs to follow an SRV (more results might come in later), or Finished if there are definitively no more results.
- Note
- ALWAYS call this before calling next()
Definition at line 192 of file DnsResult.cxx.
◆ blacklistLast()
| bool DnsResult::blacklistLast |
( |
uint64_t |
expiry | ) |
|
Blacklist the last returned result until the specified time (ms). This call is threadsafe.
- Parameters
-
| expiry | The absolute expiry, in ms, of this blacklist. |
- Returns
- true iff the last result could be blacklisted
- Note
- This is a no-op if no results have been returned.
Definition at line 147 of file DnsResult.cxx.
◆ destroy()
| void DnsResult::destroy |
( |
| ) |
|
◆ getSRVResultsSize()
| unsigned int resip::DnsResult::getSRVResultsSize |
( |
| ) |
const |
|
inline |
◆ greylistLast()
| bool DnsResult::greylistLast |
( |
uint64_t |
expiry | ) |
|
Greylist the last returned result until the specified time (ms) Greylisting a tuple effectively de-prioritizes it, so it will not be tried if there are any non-grey or blacklisted tuples left to try. This call is threadsafe.
- Parameters
-
| expiry | The absolute expiry, in ms, of this blacklist. |
- Returns
- true iff the last result could be greylisted
- Note
- This is a no-op if no results have been returned.
Definition at line 165 of file DnsResult.cxx.
◆ lookup()
| void DnsResult::lookup |
( |
const Uri & |
uri | ) |
|
Starts a lookup. Has the rules for determining the transport from a uri as per rfc3263 and then does a NAPTR lookup or an A lookup depending on the uri. Also does ENUM lookups if domain matches a configured enum domain. This call is threadsafe.
- Parameters
-
Definition at line 261 of file DnsResult.cxx.
◆ next()
| Tuple DnsResult::next |
( |
| ) |
|
Return the next tuple available for this query. Safe to call after DnsHandler::handle callback has been called.
- Returns
- The next Tuple available for this query.
- Note
- ALWAYS call available() and verify the return is Available before calling this function.
-
This no longer results in the last result being blacklisted. To blacklist the last result, use blacklistLast().
Definition at line 214 of file DnsResult.cxx.
◆ RESIP_HeapCount()
| resip::DnsResult::RESIP_HeapCount |
( |
DnsResult |
| ) |
|
◆ target()
| Data resip::DnsResult::target |
( |
| ) |
const |
|
inline |
◆ whitelistLast()
| void DnsResult::whitelistLast |
( |
| ) |
|
Whitelist the last tuple returned by next(). This means that the path to this result (NAPTR->SRV->A/AAAA) will be favored by the resolver from now on. (ie, this NAPTR will be favored above all others that match, even if the order/preference changes in the DNS, and this A/AAAA record will be favored above all others that match, even if new ones are added.) This call is threadsafe.
- Note
- It can be argued that using this is harmful, since the load- leveling capabilities of DNS are ignored from here on.
-
This will also re-order SRV records, but the order in which SRVs arrive is ignored by DnsResult (they are just re-sorted)
Definition at line 241 of file DnsResult.cxx.
◆ DnsInterface
◆ LookupCommand
| friend class LookupCommand |
|
friend |
◆ operator<< [1/3]
◆ operator<< [2/3]
◆ operator<< [3/3]
The documentation for this class was generated from the following files: