Collaboration diagram for ipcache_entry:

Classes

struct  Flags
 

Public Member Functions

void * operator new (size_t size)
 
void operator delete (void *address)
 
void * toCbdata () noexcept
 
 ipcache_entry (const char *)
 
 ~ipcache_entry ()
 
const char * name () const
 
int totalResponseTime () const
 milliseconds since the first lookup start or -1 if there were no lookups More...
 
int additionalLookupDelay () const
 milliseconds since the last lookup start or -1 if there were no lookups More...
 
template<class Specs >
void addGood (const rfc1035_rr &rr, Specs &specs)
 adds the contents of a "good" DNS A or AAAA record to stored IPs More...
 
void latestError (const char *text, const int debugLevel=3)
 remembers the last error seen, overwriting any previous errors More...
 

Public Attributes

hash_link hash
 
time_t lastref
 
time_t expires
 
ipcache_addrs addrs
 
IpCacheLookupForwarder handler
 
char * error_message
 
dlink_node lru
 
unsigned short locks
 
struct ipcache_entry::Flags flags
 
bool sawCname = false
 

Protected Member Functions

void updateTtl (const unsigned int rrTtl)
 

Static Private Attributes

static cbdata_type CBDATA_ipcache_entry = CBDATA_UNKNOWN
 

Detailed Description

The data structure used for storing name-address mappings is a small hashtable (static hash_table *ip_table), where structures of type ipcache_entry whose most interesting members are:

Definition at line 130 of file ipcache.cc.

Constructor & Destructor Documentation

ipcache_entry::ipcache_entry ( const char *  aName)
ipcache_entry::~ipcache_entry ( )

Definition at line 1080 of file ipcache.cc.

References hash, and xfree.

Member Function Documentation

template<class Specs >
void ipcache_entry::addGood ( const rfc1035_rr rr,
Specs &  specs 
)
int ipcache_entry::additionalLookupDelay ( ) const
void ipcache_entry::latestError ( const char *  text,
const int  debugLevel = 3 
)

Definition at line 456 of file ipcache.cc.

References debugs, error_message, name(), safe_free, and xstrdup.

Referenced by ipcacheHandleReply(), and ipcacheParse().

const char* ipcache_entry::name ( ) const
inline

Definition at line 156 of file ipcache.cc.

References hash, and hash_link::key.

Referenced by addGood(), ipcacheHandleReply(), ipcacheParse(), and latestError().

void ipcache_entry::operator delete ( void *  address)
inline

Definition at line 132 of file ipcache.cc.

void* ipcache_entry::operator new ( size_t  size)
inline

Definition at line 132 of file ipcache.cc.

void* ipcache_entry::toCbdata ( )
inlinenoexcept

Definition at line 132 of file ipcache.cc.

int ipcache_entry::totalResponseTime ( ) const
void ipcache_entry::updateTtl ( const unsigned int  rrTtl)
protected

Definition at line 539 of file ipcache.cc.

References Config, expires, max(), min(), SquidConfig::negativeDnsTtl, SquidConfig::positiveDnsTtl, and squid_curtime.

Referenced by addGood().

Member Data Documentation

cbdata_type ipcache_entry::CBDATA_ipcache_entry = CBDATA_UNKNOWN
staticprivate

Definition at line 132 of file ipcache.cc.

char* ipcache_entry::error_message

Definition at line 143 of file ipcache.cc.

Referenced by ipcacheCallback(), ipcacheHandleReply(), and latestError().

IpCacheLookupForwarder ipcache_entry::handler

Definition at line 142 of file ipcache.cc.

Referenced by addGood(), ipcache_nbgethostbyname_(), ipcacheCallback(), and ipcacheHandleReply().

hash_link ipcache_entry::hash
time_t ipcache_entry::lastref
unsigned short ipcache_entry::locks
dlink_node ipcache_entry::lru

Definition at line 145 of file ipcache.cc.

Referenced by ipcacheAddEntry(), ipcacheLockEntry(), and ipcacheRelease().

bool ipcache_entry::sawCname = false

Definition at line 154 of file ipcache.cc.

Referenced by ipcacheHandleReply(), and ipcacheParse().


The documentation for this class was generated from the following file:

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors