Exportieren (0) Drucken
Alle erweitern
EN
Dieser Inhalt ist in Ihrer Sprache leider nicht verfügbar. Im Folgenden finden Sie die englische Version.

in_addr structure

The in_addr structure represents an IPv4 address.

Note  The IPaddr type definition in IP Helper also represents an IPv4 address and can be cast to an interchangeable in_addr structure when needed. The in_addr structure in IP Helper has the same syntax and usage as the Windows Sockets in_addr structure, and is interchangeable with in_addr structure used in Windows sockets. Windows sockets also defines an IN_ADDR typedef for the in_addr structure.

Syntax


typedef struct {
  union {
    struct {
      u_char s_b1,s_b2,s_b3,s_b4;
    } S_un_b;
    struct {
      u_short s_w1,s_w2;
    } S_un_w;
    u_long S_addr;
  } S_un;
} IPAddr;

Members

S_un
S_un_b

The IPv4 address of the host formatted as four u_chars.

S_un_w

The IPv4 address of the host formatted as two u_shorts.

S_addr

Address of the host formatted as a u_long.

Remarks

The IPaddr type definition also represents an IPv4 address and can be cast to an in_addr structure when needed.

On the Microsoft Windows Software Development Kit (SDK) released for Windows Vista and later, the organization of header files has changed and the in_addr structure is defined in the Inaddr.h header file which is automatically included by the Ipexport.h header file. On the Platform Software Development Kit (SDK) released for Windows Server 2003 and Windows XP, the in_addr structure is declared in the Ipexport.h header file.

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Inaddr.h on Windows Server 2008 and Windows Vista (include Ipexport.h);
Ipexport.h on Windows Server 2003, Windows XP, and Windows 2000

See also

in_addr(Winsock)
SendARP
AddIPAddress
GetBestInterface
GetRTTAndHopCount
IcmpSendEcho2
IcmpSendEcho
ARP_SEND_REPLY
ICMP_ECHO_REPLY
IP_UNIDIRECTIONAL_ADAPTER_ADDRESS

 

 

Community-Beiträge

HINZUFÜGEN
Anzeigen:
© 2015 Microsoft