Прочетете на английски Редактиране

Споделяне чрез


OnChangedCallback Delegate

Definition

Defines a reference to a method that handles changes to monitored items.

public delegate void OnChangedCallback(object state);

Parameters

state
Object

The state of the dependent object that was changed.

Remarks

The OnChangedCallback delegate is used by a change monitor to signal to a cache implementation that a change has occurred in an object whose contents are cached. The task of any implementation of the ChangeMonitor type is to monitor for changes in objects that are cached. For example, if the contents of a file are contained in a cache entry, and if the file is updated, its related cache entry must be changed also. In a typical cache implementation, a derived ChangeMonitor instance uses a OnChangedCallback delegate to notify the cache about a change.

Extension Methods

GetMethodInfo(Delegate)

Gets an object that represents the method represented by the specified delegate.

Applies to

Продукт Версии
.NET 8 (package-provided), 9 (package-provided)
.NET Framework 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7 (package-provided), 4.7, 4.7.1 (package-provided), 4.7.1, 4.7.2 (package-provided), 4.7.2, 4.8 (package-provided), 4.8, 4.8.1
.NET Standard 2.0 (package-provided)

See also