API Reference | developer.brewmp.com API Reference | developer.brewmp.com


API Reference


Brew Release
Brew MP 1.0.2
See Also
Address Info Flags AEESockType IAddrInfo IAddrInfo_StartQuery() Socket Protocols
This data type represents a socket address information element to be used with IAddrInfo_StartQuery() and IAddrInfo_GetResultAddr(). See RFC 3493 section 6.1 for more details. The main exception is that the ai_next member was dropped and that psasAddr and szCanonName are typically stored in the same contiguous memory block as the AEEAddrInfo structure itself.

Usage example:

nErr = IAddrInfo_GetResult(pMe->pIAddrInfo, &nStatus, &nAddrNumber, &nMaxAddrInfoByteSize);
if (SUCCESS != nErr) { ... }

IEnv_ErrMalloc(piEnv, nMaxAddrInfoByteSize, (void**)(&pAddr)); if (!pAddr) { ... }

nErr = IAddrInfo_GetResultAddr(pMe->pIAddrInfo, 0, pAddr, &nMaxAddrInfoByteSize);
if (SUCCESS != nErr) { ... }
  • dwFlags: bit mask integer of AEE_AI_FLAG_*. Used when passed as the hints structure to IAddrInfo_StartQuery().
  • nFamily: socket address family (AEE_AF_*).
  • nSockType: socket type.
  • nProtocol: socket protocol (AEE_IPPROTO_*)
  • dwAddrLen: length of psasAddr
  • szCanonName: canonical name for nodename.
  • psasAddr: binary address.
  •    typedef struct AEEAddrInfo {
          int  dwFlags;
          int  nFamily;
          AEESockType nSockType;
          int  nProtocol;
          uint32 dwAddrLen;
          char* szCanonName;
          union AEESockAddrStorage* psasAddr;
       } AEEAddrInfo;