MprConfigTransportCreate function (mprapi.h)
The MprConfigTransportCreate function adds the specified transport to the list of transport protocols present in the specified router configuration.
Syntax
DWORD MprConfigTransportCreate(
[in] HANDLE hMprConfig,
[in] DWORD dwTransportId,
[in, optional] LPWSTR lpwsTransportName,
[in] LPBYTE pGlobalInfo,
[in] DWORD dwGlobalInfoSize,
[in, optional] LPBYTE pClientInterfaceInfo,
[in, optional] DWORD dwClientInterfaceInfoSize,
[in, optional] LPWSTR lpwsDLLPath,
[out] HANDLE *phRouterTransport
);
Parameters
[in] hMprConfig
Handle to the router configuration to which to add the transport. Obtain this handle by calling MprConfigServerConnect.
[in] dwTransportId
A DWORD value that describes the transport to add to the configuration. This parameter also identifies the router manager for the transport. Acceptable values for dwTransportId are listed in the following table.
Value | Transport (Protocol Family) |
---|---|
PID_ATALK | AppleTalk |
PID_IP | Internet Protocol version 4 |
PID_IPX | Internet Packet Exchange |
PID_NBF | NetBIOS Frames Protocol |
PID_IPV6 | Windows Server 2008 or later: Internet Protocol version 6 |
[in, optional] lpwsTransportName
Pointer to a null-terminated Unicode string that specifies the name of the transport being added. If this parameter is not specified, the dwTransportId parameter is converted into a string and used as the transport name.
[in] pGlobalInfo
Pointer to an information header that specifies global information for the transport. The router manager for the transport interprets this information. Use the Information Header Functions to manipulate information headers.
[in] dwGlobalInfoSize
Specifies the size, in bytes, of the data pointed to by the pGlobalInfo parameter.
[in, optional] pClientInterfaceInfo
Pointer to an information header that specifies default interface information for client routers. This information is used to configure dynamic interfaces for client routers for this transport. Use the Information Header Functions to manipulate information headers.
This parameter is optional; the calling application can specify NULL for this parameter.
[in, optional] dwClientInterfaceInfoSize
Specifies the size, in bytes, of the data pointed to by the pClientInterfaceInfo parameter. If the calling application specifies NULL for pClientInterfaceInfo, the calling application should specify zero for this parameter.
[in, optional] lpwsDLLPath
Pointer to a null-terminated Unicode string that specifies the name of the router manager DLL for the specified transport. If this name is specified, the function sets the DLL path for this transport to this name.
This parameter is optional; the calling application can specify NULL for this parameter.
[out] phRouterTransport
A pointer to a
HANDLE variable that receives the transport configuration handle type indicated in the dwTransportId parameter.
Return value
If the function succeeds, the return value is NO_ERROR.
If the function fails, the return value is one of the following error codes.
Value | Meaning |
---|---|
|
The hMprConfig parameter is NULL, or the phRouterTransport parameter is NULL, or both are NULL. |
|
Insufficient resources to complete the operation. |
|
Use FormatMessage to retrieve the system error message that corresponds to the error code returned. |
Remarks
If the specified transport already exists, MprConfigTransportCreate does the equivalent of an MprConfigTransportSetInfo call using the supplied parameter values.
Requirements
Requirement | Value |
---|---|
Minimum supported client | None supported |
Minimum supported server | Windows 2000 Server [desktop apps only] |
Target Platform | Windows |
Header | mprapi.h |
Library | Mprapi.lib |
DLL | Mprapi.dll |