WeakSubscriptionManager.

Subscribe<TTarget, TEventArgs>(TTarget, string, IWeakSubscriber<TEventArgs>) Method

Summary

Subscribes to an event on an object using a weak subscription.
Namespace
Avalonia.Utilities
Containing Type
WeakSubscriptionManager

Syntax

public static void Subscribe<TTarget, TEventArgs>(TTarget target, string eventName, IWeakSubscriber<TEventArgs> subscriber) 
    where TEventArgs : EventArgs

Type Parameters

Name Description
TTarget The type of the target.
TEventArgs The type of the event arguments.

Parameters

Name Type Description
target TTarget The event source.
eventName string The name of the event.
subscriber IWeakSubscriber<TEventArgs> The subscriber.

Return Value

Type Description
void