NAME

ACE_INET_Addr - Defines the Internet domain address family address format.

SYNOPSIS

#include <ace/INET_Addr.h>

class ACE_INET_Addr : public ACE_Addr { public: ACE_INET_Addr (void); ACE_INET_Addr (const ACE_INET_Addr &); ACE_INET_Addr (const sockaddr_in *, int len); ACE_INET_Addr (u_short port_number, const ASYS_TCHAR host_name[]); ACE_INET_Addr (const ASYS_TCHAR address[]); ACE_INET_Addr ( u_short port_number, ACE_UINT32 ip_addr = INADDR_ANY ); ACE_INET_Addr ( const ASYS_TCHAR port_name[], const ASYS_TCHAR host_name[] ); ACE_INET_Addr (const ASYS_TCHAR port_name[], ACE_UINT32 ip_addr); int set (const ACE_INET_Addr &); int set ( u_short port_number, const ASYS_TCHAR host_name[], int encode = 1 ); int set ( u_short port_number, ACE_UINT32 ip_addr = INADDR_ANY, int encode = 1 ); int set ( const ASYS_TCHAR port_name[], const ASYS_TCHAR host_name[] ); int set (const ASYS_TCHAR port_name[], ACE_UINT32 ip_addr); int set (const ASYS_TCHAR addr[]); int set (const sockaddr_in *, int len); virtual void *get_addr (void) const; virtual void set_addr (void *, int len); virtual int addr_to_string (ASYS_TCHAR addr[], size_t) const; virtual int string_to_addr (const ASYS_TCHAR address[]); void set_port_number (u_short, int encode = 1); u_short get_port_number (void) const; int get_host_name ( ASYS_TCHAR hostname[], size_t hostnamelen ) const; const ASYS_TCHAR *get_host_name (void) const; const char *get_host_addr (void) const; ACE_UINT32 get_ip_address (void) const; int operator == (const ACE_INET_Addr &SAP) const; int operator != (const ACE_INET_Addr &SAP) const; void dump (void) const; ACE_ALLOC_HOOK_DECLARE; private: sockaddr_in inet_addr_; };

Initialization methods.

ACE_INET_Addr (void);

ACE_INET_Addr (const ACE_INET_Addr &);

ACE_INET_Addr (const sockaddr_in *, int len);

ACE_INET_Addr (u_short port_number, const ASYS_TCHAR host_name[]);

ACE_INET_Addr (const ASYS_TCHAR address[]);

ACE_INET_Addr (u_short port_number, ACE_UINT32 ip_addr = INADDR_ANY);

ACE_INET_Addr (
    const ASYS_TCHAR port_name[],
    const ASYS_TCHAR host_name[]
    );

ACE_INET_Addr (const ASYS_TCHAR port_name[], ACE_UINT32 ip_addr);

Direct initialization methods (useful after the object has been

constructed).
int set (const ACE_INET_Addr &);

int set (
    u_short port_number,
    const ASYS_TCHAR host_name[],
    int encode = 1
    );

int set (
    u_short port_number,
    ACE_UINT32 ip_addr = INADDR_ANY,
    int encode = 1
    );

int set (const ASYS_TCHAR port_name[], const ASYS_TCHAR host_name[]);

int set (const ASYS_TCHAR port_name[], ACE_UINT32 ip_addr);

int set (const ASYS_TCHAR addr[]);

int set (const sockaddr_in *, int len);

virtual void *get_addr (void) const;

virtual void set_addr (void *, int len);

virtual int addr_to_string (ASYS_TCHAR addr[], size_t) const;

virtual int string_to_addr (const ASYS_TCHAR address[]);

void set_port_number (u_short, int encode = 1);

u_short get_port_number (void) const;

int get_host_name (ASYS_TCHAR hostname[], size_t hostnamelen) const;

const ASYS_TCHAR *get_host_name (void) const;

const char *get_host_addr (void) const;

ACE_UINT32 get_ip_address (void) const;

int operator == (const ACE_INET_Addr &SAP) const;

int operator != (const ACE_INET_Addr &SAP) const;

void dump (void) const;

ACE_ALLOC_HOOK_DECLARE;

AUTHOR

Doug Schmidt

LIBRARY

ace