Table of Contents

Class TimeoutItemUtil

Namespace
VpnHood.Net.Toolkit.Collections
Assembly
VpnHood.Net.Toolkit.dll

Provides the means to clean a list of timeout items.

public static class TimeoutItemUtil
Inheritance
TimeoutItemUtil
Inherited Members

Methods

CleanupTimeoutList<T>(List<T>, TimeSpan)

Removes from a list, and disposes, the items that are disposed or unused for longer than a timeout.

public static void CleanupTimeoutList<T>(List<T> list, TimeSpan timeout) where T : ITimeoutItem

Parameters

list List<T>

The list; it is not safe for concurrent use.

timeout TimeSpan

How long an item may go unused.

Type Parameters

T

The type of the items.