次の方法で共有


IXPLogon::TransportLogoff

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

Initiates the logoff process.

HRESULT TransportLogoff(
  ULONG ulFlags
);

Parameters

  • ulFlags
    [in] Reserved; must be zero.

Return Value

  • S_OK
    The call succeeded and returned the expected value or values. If anything other than S_OK is returned, the provider is logged off.

Remarks

The MAPI spooler calls the IXPLogon::TransportLogoff method to terminate a transport provider session for a particular user. Before calling TransportLogoff, the MAPI spooler discards any data about supported messaging address types for this session passed in the IXPLogon::AddressTypes method.

Notes to Implementers

The transport provider should be prepared to accept a call to TransportLogoff at any time. If a message is in process, the provider should stop the sending process.

The transport provider should release all resources allocated for its current session. If it has allocated any memory for this session with the MAPIAllocateBuffer function, it should free the memory by using the MAPIFreeBuffer function. Any memory allocated by the transport provider to satisfy calls to the IXPLogon::AddressTypes, IXPLogon::RegisterOptions, and IMAPISession::MessageOptions methods can be safely released at this time.

Usually, on completing a TransportLogoff call, a provider should first invalidate its logon object by calling the IMAPISupport::MakeInvalid method and then release its support object. The provider's implementation of TransportLogoff should release the support object last, because when the support object is released, the MAPI spooler can also release the provider object itself.

See Also

Reference

IMAPISession::MessageOptions

IMAPISupport::MakeInvalid

IMAPISupport::SpoolerYield

IXPLogon::AddressTypes

IXPLogon::RegisterOptions

MAPIAllocateBuffer

MAPIFreeBuffer

IXPLogon : IUnknown