/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
/* ** Base class definitions for network access functions (ref: prnetdb.h)
*/
#ifdefined(_RCNETDB_H) #else #define _RCNETDB_H
#include"rclock.h" #include"rcbase.h"
#include <prnetdb.h>
class PR_IMPLEMENT(RCNetAddr): public RCBase
{ public: typedefenum {
any = PR_IpAddrAny, /* assign logical INADDR_ANY */
loopback = PR_IpAddrLoopback /* assign logical INADDR_LOOPBACK */
} HostValue;
virtual PRBool operator==(const RCNetAddr&) const; /* compare of all relavent fields */ virtual PRBool EqualHost(const RCNetAddr&) const; /* compare of just host field */
public:
voidoperator=(const PRNetAddr*); /* construction from more primitive data */ operatorconst PRNetAddr*() const; /* extraction of underlying representation */ virtual PRStatus FromString(constchar* string); /* initialization from an ASCII string */ virtual PRStatus ToString(char *string, PRSize size) const; /* convert internal fromat to a string */
private:
PRNetAddr address;
}; /* RCNetAddr */
/* ** Class: RCHostLookup ** ** Abstractions to look up host names and addresses. ** ** This is a stateful class. One looks up the host by name or by ** address, then enumerates over a possibly empty array of network ** addresses. The storage for the addresses is owned by the class.
*/
class RCHostLookup: public RCBase
{ public: virtual ~RCHostLookup();
¤ Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.0.13Bemerkung:
(vorverarbeitet)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.