OnChangedCallback Delegar

Definição

Define uma referência a um método que lida com alterações a itens monitorados.Defines a reference to a method that handles changes to monitored items.

public delegate void OnChangedCallback(System::Object ^ state);
public delegate void OnChangedCallback(object state);
type OnChangedCallback = delegate of obj -> unit
Public Delegate Sub OnChangedCallback(state As Object)

Parâmetros

state
Object

O estado do objeto dependente que foi alterado.The state of the dependent object that was changed.

Comentários

O OnChangedCallback delegado é usado por um monitor de alteração para sinalizar para uma implementação de cache que ocorreu uma alteração em um objeto cujo conteúdo é armazenado em cache.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. A tarefa de qualquer implementação do ChangeMonitor tipo é monitorar as alterações nos objetos armazenados em cache.The task of any implementation of the ChangeMonitor type is to monitor for changes in objects that are cached. Por exemplo, se o conteúdo de um arquivo estiver contido em uma entrada de cache, e se o arquivo for atualizado, sua entrada de cache relacionada também deverá ser alterada.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. Em uma implementação de cache típica, uma ChangeMonitor instância derivada usa um OnChangedCallback delegado para notificar o cache sobre uma alteração.In a typical cache implementation, a derived ChangeMonitor instance uses a OnChangedCallback delegate to notify the cache about a change.

Métodos de Extensão

GetMethodInfo(Delegate)

Obtém um objeto que representa o método representado pelo delegado especificado.Gets an object that represents the method represented by the specified delegate.

Aplica-se a

Confira também