Module: Essential Networking Module Package: Networking
Does not inherit
getDomain() getFamily() getFamilyName() |
getProtocol() getType() id() |
operator!=() operator==() RWSockType() |
#include <rw/network/RWSockType.h>
RWSockType represents a type of socket communications channel. It is made up of a family (or domain), a type, and a protocol. An example of a family is the Internet TCP/IP family AF_INET. A socket type is SOCK_STREAM or SOCK_DGRAM. A protocol could be PF_INET or PF_UNSPEC.
RWSockType();
Builds an invalid socket type. To set it to a valid type, use the assignment operator.
RWSockType(const RWCString& familyName, int domain, int type=SOCK_STREAM, int protocol=0);
Builds a socket communication type descriptor. The domain specifies the type of communications channel. For the Internet domain, it is AF_INET; for the Unix domain, it is AF_UNIX. type specifies the type of channel, usually SOCK_STREAM or SOCK_DGRAM. The RWCString should contain 7-bit US-ASCII data.
~RWSockType();
Destructor.
bool operator==(const RWSockType&) const;
Returns true if all of the components (name, family, type, protocol) in the two classes are equivalent.
bool operator!=(const RWSockType&) const;
Returns true if any of the components (name, family, type, protocol) differ between the two classes.
int getDomain() const; int getFamily() const;
Returns the integer identifier of the address domain for the socket type, such as AF_INET for an Internet domain address. getFamily() and getDomain() are synonyms.
RWCString getFamilyName() const;
Returns a string representation of the address domain, such as "inet" for the Internet address domain. The RWCString should contain 7-bit US-ASCII data.
int getProtocol() const;
Gets the protocol family that describes the socket type.
int getType() const;
Gets the socket type that describes the socket protocol.
RWCString id(unsigned level=0) const;
Returns a string describing self. The verbosity of the output is controlled by level where level=0 is the most basic, and level=9 is the most verbose. The RWCString should contain 7-bit US-ASCII data.
© Copyright Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave and SourcePro are registered trademarks of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.
Contact Rogue Wave about documentation or support issues.