]> git.ipfire.org Git - thirdparty/squid.git/blobdiff - src/icmp/net_db.h
SourceFormat Enforcement
[thirdparty/squid.git] / src / icmp / net_db.h
index 2c523c2064b3358d47841ba9881acaf99128436f..1e944e63c54e5fce19cd90ab590ef2edf487abbf 100644 (file)
@@ -1,26 +1,37 @@
+/*
+ * Copyright (C) 1996-2015 The Squid Software Foundation and contributors
+ *
+ * Squid software is distributed under GPLv2+ license and includes
+ * contributions from numerous individuals and organizations.
+ * Please see the COPYING and CONTRIBUTORS files for details.
+ */
+
 #ifndef ICMP_NET_DB_H
 #define ICMP_NET_DB_H
 
-#include "CachePeer.h"
 #include "hash.h"
 
+class CachePeer;
+class HttpRequest;
+class netdbEntry;
+class StoreEntry;
 namespace Ip
 {
 class Address;
 };
 
-class StoreEntry;
-class HttpRequest;
-class netdbEntry;
-
-class net_db_name {
+// POD
+class net_db_name
+{
 public:
     hash_link hash;     /* must be first */
     net_db_name *next;
     netdbEntry *net_db_entry;
 };
 
-class net_db_peer {
+// POD
+class net_db_peer
+{
 public:
     const char *peername;
     double hops;
@@ -28,7 +39,9 @@ public:
     time_t expires;
 };
 
-class netdbEntry {
+// POD
+class netdbEntry
+{
 public:
     hash_link hash;     /* must be first */
     char network[MAX_IPSTRLEN];
@@ -45,23 +58,24 @@ public:
     int n_peers;
 };
 
-extern void netdbInit(void);
+void netdbInit(void);
 
-extern void netdbHandlePingReply(const Ip::Address &from, int hops, int rtt);
-extern void netdbPingSite(const char *hostname);
+void netdbHandlePingReply(const Ip::Address &from, int hops, int rtt);
+void netdbPingSite(const char *hostname);
 void netdbDump(StoreEntry *);
 
-extern void netdbFreeMemory(void);
-extern int netdbHostHops(const char *host);
-extern int netdbHostRtt(const char *host);
-extern void netdbUpdatePeer(HttpRequest *, CachePeer * e, int rtt, int hops);
+void netdbFreeMemory(void);
+int netdbHostHops(const char *host);
+int netdbHostRtt(const char *host);
+void netdbUpdatePeer(HttpRequest *, CachePeer * e, int rtt, int hops);
 
-extern void netdbDeleteAddrNetwork(Ip::Address &addr);
-extern void netdbBinaryExchange(StoreEntry *);
-extern void netdbExchangeStart(void *);
+void netdbDeleteAddrNetwork(Ip::Address &addr);
+void netdbBinaryExchange(StoreEntry *);
+void netdbExchangeStart(void *);
 
-extern void netdbExchangeUpdatePeer(Ip::Address &, CachePeer *, double, double);
-extern CachePeer *netdbClosestParent(HttpRequest *);
-extern void netdbHostData(const char *host, int *samp, int *rtt, int *hops);
+void netdbExchangeUpdatePeer(Ip::Address &, CachePeer *, double, double);
+CachePeer *netdbClosestParent(HttpRequest *);
+void netdbHostData(const char *host, int *samp, int *rtt, int *hops);
 
 #endif /* ICMP_NET_DB_H */
+