MprConfigTransportSetInfo

The MprConfigTransportSetInfo function changes the configuration for the specified transport in the specified router configuration.

DWORD MprConfigTransportSetInfo(
  HANDLE hMprConfig,                // handle to the router configuration
  HANDLE hRouterTransport,          // handle to the transport configuration
  LPBYTE pGlobalInfo,               // global information for the transport
  DWORD dwGlobalInfoSize,           // size of global information
  LPBYTE pClientInterfaceInfo,      // interface information for
                                    // client routers
  DWORD dwClientInterfaceInfoSize,  // size of interface information
  LPWSTR lpwsDLLPath                // name of router manager DLL
);

Parameters

hMprConfig
[in] Handle to the router configuration. Obtain this handle by calling MprConfigServerConnect.
hRouterTransport
[in] Handle to the transport configuration being updated. Obtain this handle by calling MprConfigTransportCreate, MprConfigTransportGetHandle, or MprConfigTransportEnum.
pGlobalInfo
[in] 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.

This parameter is optional; the calling application may specify NULL for this parameter.

dwGlobalInfoSize
[in] Specifies the size, in bytes, of the data pointed to by pGlobalInfo. If the calling application specifies NULL for pGlobalInfo, the calling application should specify zero for this parameter.
pClientInterfaceInfo
[in] Pointer to an information header that specifies default interface information for client routers. The 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 may specify NULL for this parameter.

dwClientInterfaceInfoSize
[in] Specifies the size, in bytes, of the data pointed to by pClientInterfaceInfo. If the calling application specifies NULL for pClientInterfaceInfo, the calling application should specify zero for this parameter.
lpwsDLLPath
[in] Specifies the name of the router manager DLL for the specified transport.

This parameter is optional; the calling application may specify NULL for this parameter.

Return Values

If the function succeeds, the return value is NO_ERROR. For more information, see the Remarks section later in this topic.

If the function fails, the return value is one of the following error codes.

Value Meaning
ERROR_INVALID_PARAMETER The hMprConfig parameter is NULL, the hRouterTransport parameter is NULL, or both are NULL.
ERROR_UNKNOWN_PROTOCOL_ID The transport configuration that corresponds to hRouterTransport was not found in the router configuration.
Other Use FormatMessage to retrieve the system error message that corresponds to the error code returned.

Remarks

Use MprConfigTransportSetInfo to set the transport's global information, default interface information, or the name of the router manager DLL for the transport.

MprConfigTransportSetInfo attempts to set the items in the order in which they appear in the parameter list:

  1. Global information
  2. Default interface information for client routers
  3. Router manager DLL name

If MprConfigTransportSetInfo is unable to set any one of the items, it returns immediately without attempting to set the remaining items.

If the pGlobalInfo, pClientInterfaceInfo, and lpwsDLLPath parameters are all NULL, the function does nothing, returning a value of NO_ERROR.

Requirements

  Windows NT/2000: Requires Windows 2000.
  Header: Declared in Mprapi.h.
  Library: Use Mprapi.lib.

See Also

Router Management Reference, Router Configuration Functions, FormatMessage, MprConfigServerConnect, MprConfigTransportCreate, MprConfigTransportEnum, MprConfigTransportGetHandle