Class SynchronizedList<T>
- Namespace
- ToSic.Sys.Caching.Synchronized
- Assembly
- ToSic.Sys.Caching.dll
This is an IEnumerable which relies on an up-stream cache, which may change. That would require this IEnumerable to update what it delivers.
[InternalApi_DoNotUse_MayChangeWithoutNotice("this is just fyi")]
public class SynchronizedList<T> : SynchronizedObject<IImmutableList<T>>, ICacheDependent, ICacheExpiring, ITimestamped, IEnumerable<T>, IEnumerable
Type Parameters
T
The type which is enumerated, usually an
IEntity
- Inheritance
-
objectSynchronizedList<T>
- Implements
-
IEnumerable<T>
- Inherited Members
Constructors
SynchronizedList(ICacheExpiring, Func<IImmutableList<T>>)
This is an IEnumerable which relies on an up-stream cache, which may change. That would require this IEnumerable to update what it delivers.
public SynchronizedList(ICacheExpiring upstream, Func<IImmutableList<T>> rebuild)
Parameters
upstream
ICacheExpiringthe upstream cache which can tell us if a refresh is necessary
rebuild
Func<IImmutableList<T>>the method which rebuilds the list