jdk/src/windows/native/java/net/NetworkInterface.h
changeset 906 17568a617956
parent 2 90ce3da70b43
child 910 1f53246fb014
equal deleted inserted replaced
905:8445a646acfb 906:17568a617956
    24  */
    24  */
    25 
    25 
    26 #ifndef NETWORK_INTERFACE_H
    26 #ifndef NETWORK_INTERFACE_H
    27 #define NETWORK_INTERFACE_H
    27 #define NETWORK_INTERFACE_H
    28 
    28 
       
    29 #include <iphlpapi.h>
    29 #include "net_util.h"
    30 #include "net_util.h"
    30 
    31 
    31 /*
    32 /*
    32  * Structures used when enumerating interfaces and addresses
    33  * Structures used when enumerating interfaces and addresses
    33  */
    34  */
    83 extern jclass ni_ibcls;             /* InterfaceAddress */
    84 extern jclass ni_ibcls;             /* InterfaceAddress */
    84 extern jmethodID ni_ibctrID;        /* InterfaceAddress() */
    85 extern jmethodID ni_ibctrID;        /* InterfaceAddress() */
    85 extern jfieldID ni_ibaddressID;     /* InterfaceAddress.address */
    86 extern jfieldID ni_ibaddressID;     /* InterfaceAddress.address */
    86 extern jfieldID ni_ibbroadcastID;   /* InterfaceAddress.broadcast */
    87 extern jfieldID ni_ibbroadcastID;   /* InterfaceAddress.broadcast */
    87 extern jfieldID ni_ibmaskID;        /* InterfaceAddress.maskLength */
    88 extern jfieldID ni_ibmaskID;        /* InterfaceAddress.maskLength */
       
    89 
       
    90 /* We have included iphlpapi.h which includes iptypes.h which has the definition
       
    91  * for MAX_ADAPTER_DESCRIPTION_LENGTH (along with the other definitions in this
       
    92  * ifndef block). Therefore if MAX_ADAPTER_DESCRIPTION_LENGTH is defined we can
       
    93  * be sure that the other definitions are also defined */
       
    94 #ifndef MAX_ADAPTER_DESCRIPTION_LENGTH
    88 
    95 
    89 /*
    96 /*
    90  * Following includes come from iptypes.h
    97  * Following includes come from iptypes.h
    91  */
    98  */
    92 
    99 
   370     char ScopeId[MAX_SCOPE_ID_LEN + 4];
   377     char ScopeId[MAX_SCOPE_ID_LEN + 4];
   371     UINT EnableRouting;
   378     UINT EnableRouting;
   372     UINT EnableProxy;
   379     UINT EnableProxy;
   373     UINT EnableDns;
   380     UINT EnableDns;
   374 } FIXED_INFO, *PFIXED_INFO;
   381 } FIXED_INFO, *PFIXED_INFO;
       
   382 #endif /*!MAX_ADAPTER_DESCRIPTION_LENGTH*/
   375 
   383 
   376 #ifndef IP_INTERFACE_NAME_INFO_DEFINED
   384 #ifndef IP_INTERFACE_NAME_INFO_DEFINED
   377 #define IP_INTERFACE_NAME_INFO_DEFINED
   385 #define IP_INTERFACE_NAME_INFO_DEFINED
   378 
   386 
   379 typedef struct ip_interface_name_info {
   387 typedef struct ip_interface_name_info {