7 instantiations of LazyHelper
System.Private.CoreLib (7)
22 references to LazyHelper
System.Private.CoreLib (22)
src\libraries\System.Private.CoreLib\src\System\Lazy.cs (22)
45internal static readonly LazyHelper NoneViaConstructor = new LazyHelper(LazyState.NoneViaConstructor);
46internal static readonly LazyHelper NoneViaFactory = new LazyHelper(LazyState.NoneViaFactory);
47internal static readonly LazyHelper PublicationOnlyViaConstructor = new LazyHelper(LazyState.PublicationOnlyViaConstructor);
48internal static readonly LazyHelper PublicationOnlyViaFactory = new LazyHelper(LazyState.PublicationOnlyViaFactory);
49internal static readonly LazyHelper PublicationOnlyWaitForOtherThreadToPublish = new LazyHelper(LazyState.PublicationOnlyWait);
124internal static LazyThreadSafetyMode? GetMode(LazyHelper? state)
131internal static bool GetIsValueFaulted(LazyHelper? state) => state?._exceptionDispatch != null;
133internal static LazyHelper Create(LazyThreadSafetyMode mode, bool useDefaultConstructor)
188private static T CreateViaDefaultConstructor() => LazyHelper.CreateViaDefaultConstructor<T>();
191private volatile LazyHelper? _state;
250this(null, LazyHelper.GetModeFromIsThreadSafe(isThreadSafe), useDefaultConstructor: true)
277this(valueFactory, LazyHelper.GetModeFromIsThreadSafe(isThreadSafe), useDefaultConstructor: false)
305_state = LazyHelper.Create(mode, useDefaultConstructor);
331private void ExecutionAndPublication(LazyHelper executionAndPublication, bool useDefaultConstructor)
351private void PublicationOnly(LazyHelper publicationOnly, T possibleValue)
353LazyHelper? previous = Interlocked.CompareExchange(ref _state, LazyHelper.PublicationOnlyWaitForOtherThreadToPublish, publicationOnly);
362private void PublicationOnlyViaConstructor(LazyHelper initializer)
367private void PublicationOnlyViaFactory(LazyHelper initializer)
395LazyHelper? state = _state;
465internal LazyThreadSafetyMode? Mode => LazyHelper.GetMode(_state);
470internal bool IsValueFaulted => LazyHelper.GetIsValueFaulted(_state);