Developer

API Reference

IAddrInfo_SelectNetwork()

Brew Release
Brew MP 1.0.2
See Also
AddrInfo error codes Data networks Error Codes
Description
This function selects a specific data network.
Parameters
  • me
    []:
    the interface pointer
  • nNetwork
    [in]:
    data network type (AEE_NETWORK_*)
Interface
Prototype
   int IAddrInfo_SelectNetwork(IAddrInfo *me, int nNetwork);
Return
AEE_SUCCESS: the data network was selected AEE_EBADSTATE: the network is not valid AEE_NET_EOPNOTSUPP: the network has already been selected. AEE_EFAILED: other error.
Other error codes are also possible.
Side Effect
None.
Comment
When an IAddrInfo instance is created, no network is selected. If an IAddrInfo method that requires a network (i.e. StartQuery) is called before IAddrInfo_SelectNetwork(), AEE_NETWORK_DEFAULT will be implicitly selected, and the decision of which network to actually use is deferred to lower layers.
Once a network has been selected, either explicitly via IAddrInfo_SelectNetwork(), or implicitly as described above, the network may not be changed. To use a different network, a new IAddrInfo instance is required.
  • Follow