ChangeMonitor::OnChanged Method (Object^)

.NET Framework (current version)

Called by derived classes to raise the event when a dependency changes.

Namespace:   System.Runtime.Caching
Assembly:  System.Runtime.Caching (in System.Runtime.Caching.dll)

void OnChanged(
	Object^ state


Type: System::Object^

The data for the change event. This value can be null.

Typically, the OnChanged method is called when dependency changes occur. The OnChanged method is also invoked when a change-monitor instance is disposed but the disposal occurs only if the callback has not already been invoked.

If the OnChanged method is called before the NotifyOnChanged method is called, the state data from the call to the OnChanged method is saved by the cache implementation. Also, the callback to the OnChangedCallback method is invoked immediately when the NotifyOnChanged method is invoked.

.NET Framework
Available since 4.0
Return to top