This documentation is archived and is not being maintained.

IInstanceContextProvider.NotifyIdle Method

Called when the IsIdle method returns false to enable implementers to provide a callback to notify WCF when the InstanceContext object is finished.

Namespace:  System.ServiceModel.Dispatcher
Assembly:  System.ServiceModel (in System.ServiceModel.dll)

void NotifyIdle(
	InstanceContextIdleCallback callback,
	InstanceContext instanceContext
)

Parameters

callback
Type: System.ServiceModel.Dispatcher.InstanceContextIdleCallback

The System.ServiceModel.Dispatcher.InstanceContextIdleCallback object that notifies WCF when the InstanceContext object is to be closed and recycled.

instanceContext
Type: System.ServiceModel.InstanceContext

The current InstanceContext.

The NotifyIdle method is called when the IsIdle method returns false to enable you to provide WCF with a System.ServiceModel.Dispatcher.InstanceContextIdleCallback object that you use to inform the runtime that the InstanceContext has finished its work. When the System.ServiceModel.Dispatcher.InstanceContextIdleCallback object notifies the runtime that the InstanceContext has finished its work, WCF calls IsIdle once again. This cycle continues until IsIdle returns true and the context is closed and recycled.

Windows 7, Windows Vista, Windows XP SP2, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5, 3.0
Show: