CachedSynchronizedList

Ecng.Collections

Represents a thread-safe list with a cached array of its elements for improved performance.

Herda de: SynchronizedList<T>

Construtores

CachedSynchronizedList
public CachedSynchronizedList()
cachedSynchronizedList = CachedSynchronizedList()

Initializes a new instance of the CachedSynchronizedList class.

CachedSynchronizedList
public CachedSynchronizedList(int capacity)
cachedSynchronizedList = CachedSynchronizedList(capacity)

Initializes a new instance of the CachedSynchronizedList class with the specified initial capacity.

capacity
The initial number of elements that the list can contain.

Propriedades

Cache
public T[] Cache { get; }
value = cachedSynchronizedList.Cache

Gets a cached array of the elements in the list.

Métodos

OnChanged
protected override void OnChanged()
cachedSynchronizedList.OnChanged()

Called when the list is modified to reset the cached array.