1 #ifndef __XRDNETADDRINFO_HH__
2 #define __XRDNETADDRINFO_HH__
36 #include <netinet/in.h>
37 #include <sys/socket.h>
156 && IN6_IS_ADDR_V4MAPPED(&
IP.
v6.sin6_addr);
226 const char *
Name(
const char *eName=0,
const char **eText=0);
305 {memmove(&
IP, &rhs.
IP,
sizeof(
IP));
313 if (rhs.sockAddr != &rhs.
IP.
Addr)
314 {
if (!unixPipe || sockAddr == &
IP.
Addr)
315 unixPipe =
new sockaddr_un;
316 memcpy(unixPipe, rhs.unixPipe,
sizeof(sockaddr_un));
317 }
else sockAddr = &
IP.
Addr;
349 if (sockAddr != &
IP.
Addr)
delete unixPipe;
354 int QFill(
char *bAddr,
int bLen);
360 union {
struct sockaddr *sockAddr;
361 struct sockaddr_un *unixPipe;
static XrdNetCache * dnsCache
static const int noPort
Do not add port number.
const sockaddr * SockAddr()
static const int old6Map4
Use deprecated IPV6 mapped format.
XrdNetAddrInfo & operator=(XrdNetAddrInfo const &rhs)
Assignment operator.
~XrdNetAddrInfo()
Destructor.
static bool isHostName(const char *name)
XrdNetAddrInfo()
Constructor.
const XrdNetSockAddr * NetAddr()
static const int noPortRaw
Use raw address format (no port)
int Same(const XrdNetAddrInfo *ipAddr, bool plusPort=false)
const struct LocInfo * Location()
static const int prefipv4
Use if mapped IPV4 actual format.
bool isIPType(IPType ipType) const
int Format(char *bAddr, int bLen, fmtUse fmtType=fmtAuto, int fmtOpts=0)
XrdNetAddrInfo(XrdNetAddrInfo const &oP)
Copy constructor.
char * LowCase(char *str)
int QFill(char *bAddr, int bLen)
@ fmtAddr
Address using suitable ipv4 or ipv6 format.
@ fmtName
Hostname if it is resolvable o/w use fmtAddr.
@ fmtAuto
Hostname if already resolved o/w use fmtAddr.
static const char isTLS
Location using TLS.
const char * Name(const char *eName=0, const char **eText=0)
XrdNetAddrInfo(const XrdNetAddrInfo *addr)
int Latitude
Degrees +/- xx.xxxxxx (not supported)
unsigned char Region
Region (may combine adjacent countries)
char TimeZone
+/- hours from GMT (-128 if not set)
unsigned char Country[2]
Two letter TLD country code.
short Speed
I/F speed (Gb*1024/100)(not supported)
unsigned char Locale
Locale (may combine adjacent regions)
int Longtitude
Degrees +/- xx.xxxxxx (not supported)