C# Класс GSF.Threading.WeakActionFast

Provides a high speed weak referenced action delegate. This one does not use reflection, so calls will be faster. HOWEVER: a strong reference MUST be maintained for the Action delegate passed to this class. This reference is outputted in the constructor. Careful consideration must be made when deciding where to store this strong reference, as this strong reference will need to also lose reference. A good place would be as a member variable of the object of the target method.
Наследование: System.WeakReference
Показать файл Открыть проект

Открытые методы

Метод Описание
Clear ( ) : void
WeakActionFast ( System.Action target, object &localStrongReference ) : System

Creates a high speed weak action

Приватные методы

Метод Описание
TryInvoke ( ) : bool

Описание методов

Clear() публичный Метод

public Clear ( ) : void
Результат void

WeakActionFast() публичный Метод

Creates a high speed weak action
public WeakActionFast ( System.Action target, object &localStrongReference ) : System
target System.Action the callback
localStrongReference object a strong reference that must be /// maintained in the class that is the target of the action
Результат System