1240 references to Func
Client.ClientBase.IntegrationTests (1)
Client.ExpectedExceptions.IntegrationTests (2)
ClientSample (7)
DefaultBuilder.SampleApp (1)
dotnet-dev-certs (7)
dotnet-getdocument (7)
dotnet-openapi (8)
dotnet-sql-cache (7)
dotnet-svcutil-lib (17)
dotnet-user-jwts (7)
dotnet-user-secrets (7)
ExceptionHandlerSample (1)
GetDocument.Insider (7)
IIS.FunctionalTests (3)
IIS.LongTests (3)
IIS.NewHandler.FunctionalTests (3)
IIS.NewShim.FunctionalTests (3)
IIS.ShadowCopy.Tests (3)
IISExpress.FunctionalTests (3)
illink (2)
Infrastructure.Common (1)
InMemory.FunctionalTests (4)
Interop.FunctionalTests (3)
InteropClient (1)
Microsoft.Arcade.Common (12)
Microsoft.AspNetCore.Analyzer.Testing (1)
Microsoft.AspNetCore.App.Analyzers.Test (1)
Microsoft.AspNetCore.Authentication.Test (2)
Microsoft.AspNetCore.Authorization.Policy (1)
Microsoft.AspNetCore.Components (29)
Microsoft.AspNetCore.Components.Authorization.Tests (5)
Microsoft.AspNetCore.Components.Forms (13)
Microsoft.AspNetCore.Components.Forms.Tests (6)
Microsoft.AspNetCore.Components.Server (6)
Microsoft.AspNetCore.Components.Tests (46)
RendererTest.cs (19)
629OnArbitraryDelegateEvent = (Func<Task>)(() => Task.CompletedTask),
1183builder.AddComponentParameter(1, nameof(EventComponent.OnClickEventCallback), EventCallback.Factory.Create(parentComponent, (Func<Task>)(() =>
1302builder.AddComponentParameter(1, nameof(EventComponent.OnClickEventCallbackOfT), EventCallback.Factory.Create<DerivedEventArgs>(parentComponent, (Func<Task>)(() =>
1648builder.AddComponentParameter(1, nameof(EventComponent.OnClickAsyncAction), (Func<Task>)(async () =>
1759builder.AddComponentParameter(1, nameof(EventComponent.OnClickAsyncAction), (Func<Task>)(async () =>
1879builder.AddComponentParameter(1, nameof(EventComponent.OnClickAsyncAction), (Func<Task>)(async () =>
2320builder.AddComponentParameter(1, nameof(AsyncDisposableComponent.AsyncDisposeAction), (Func<ValueTask>)(() => throw exception1));
2354builder.AddComponentParameter(1, nameof(AsyncDisposableComponent.AsyncDisposeAction), (Func<ValueTask>)(() => default));
2394builder.AddComponentParameter(1, nameof(AsyncDisposableComponent.AsyncDisposeAction), (Func<ValueTask>)(async () => { await tcs.Task; }));
2439builder.AddComponentParameter(1, nameof(AsyncDisposableComponent.AsyncDisposeAction), (Func<ValueTask>)(async () => { await tcs.Task; throw exception1; }));
2478builder.AddComponentParameter(1, nameof(AsyncDisposableComponent.AsyncDisposeAction), (Func<ValueTask>)(() => throw new TaskCanceledException()));
2516(Func<ValueTask>)(() => new ValueTask(tcs.Task)));
4274builder.AddComponentParameter(1, nameof(AsyncDisposableComponent.AsyncDisposeAction), (Func<ValueTask>)(() => { disposed = true; throw exception1; }));
4302builder.AddComponentParameter(1, nameof(AsyncDisposableComponent.AsyncDisposeAction), (Func<ValueTask>)(async () => { await tcs.Task; disposed = true; throw exception1; }));
4911builder.AddComponentParameter(1, nameof(AsyncDisposableComponent.AsyncDisposeAction), (Func<ValueTask>)(async () => await exception2Tcs.Task));
5292public Func<Task> OnClickAsyncAction { get; set; }
5546public Func<ValueTask> AsyncDisposeAction { get; set; }
5800public Func<Task<(int id, EventType @event)>> EventAction { get; set; }
6052public Func<Task> Callback { get; set; }
Microsoft.AspNetCore.Components.Web (7)
Microsoft.AspNetCore.Components.Web.Tests (7)
Microsoft.AspNetCore.Components.WebAssembly (10)
Microsoft.AspNetCore.Components.WebView.Photino (12)
Microsoft.AspNetCore.Connections.Abstractions (2)
Microsoft.AspNetCore.Cryptography.Internal (3)
Microsoft.AspNetCore.Cryptography.Internal.Tests (3)
Microsoft.AspNetCore.DataProtection (17)
Microsoft.AspNetCore.DataProtection.StackExchangeRedis (4)
Microsoft.AspNetCore.DataProtection.Tests (3)
Microsoft.AspNetCore.Grpc.JsonTranscoding.IntegrationTests (3)
Microsoft.AspNetCore.Grpc.JsonTranscoding.Tests (3)
Microsoft.AspNetCore.Grpc.Swagger (2)
Microsoft.AspNetCore.Hosting.Tests (4)
Microsoft.AspNetCore.Http (1)
Microsoft.AspNetCore.Http.Abstractions (5)
Microsoft.AspNetCore.Http.Abstractions.Tests (1)
Microsoft.AspNetCore.Http.Connections.Client (5)
Microsoft.AspNetCore.Http.Connections.Tests (3)
Microsoft.AspNetCore.Http.Extensions (1)
Microsoft.AspNetCore.Http.Extensions.Tests (53)
RequestDelegateFactoryTests.cs (53)
1325new object[] { (Func<JsonTodo>)TestAction },
1326new object[] { (Func<Task<JsonTodo>>)TaskTestAction},
1327new object[] { (Func<Task<JsonTodo>>)TaskTestActionAwaited},
1328new object[] { (Func<ValueTask<JsonTodo>>)ValueTaskTestAction},
1329new object[] { (Func<ValueTask<JsonTodo>>)ValueTaskTestActionAwaited},
1446new object[] { (Func<CustomResult>)TestAction },
1447new object[] { (Func<Task<CustomResult>>)TaskTestAction},
1448new object[] { (Func<ValueTask<CustomResult>>)ValueTaskTestAction},
1449new object[] { (Func<FSharp.Control.FSharpAsync<CustomResult>>)FSharpAsyncTestAction },
1451new object[] { (Func<CustomResult>)StaticTestAction},
1452new object[] { (Func<Task<CustomResult>>)StaticTaskTestAction},
1453new object[] { (Func<ValueTask<CustomResult>>)StaticValueTaskTestAction},
1454new object[] { (Func<FSharp.Control.FSharpAsync<CustomResult>>)StaticFSharpAsyncTestAction },
1456new object[] { (Func<object>)StaticResultAsObject},
1458new object[] { (Func<Task<object>>)StaticTaskOfIResultAsObject},
1459new object[] { (Func<ValueTask<object>>)StaticValueTaskOfIResultAsObject},
1460new object[] { (Func<FSharp.Control.FSharpAsync<object>>)StaticFSharpAsyncOfIResultAsObject},
1462new object[] { (Func<StructResult>)TestStructAction },
1463new object[] { (Func<Task<StructResult>>)TaskTestStructAction },
1464new object[] { (Func<ValueTask<StructResult>>)ValueTaskTestStructAction },
1465new object[] { (Func<FSharp.Control.FSharpAsync<StructResult>>)FSharpAsyncTestStructAction },
1500new object[] { (Func<IResult?>)TestAction, "The IResult returned by the Delegate must not be null." },
1501new object[] { (Func<Task<IResult?>?>)TaskNullAction, "The IResult in Task<IResult> response must not be null." },
1502new object[] { (Func<Task<bool?>?>)TaskBoolAction, "The Task returned by the Delegate must not be null." },
1503new object[] { (Func<Task<IResult?>>)TaskTestAction, "The IResult returned by the Delegate must not be null." },
1504new object[] { (Func<ValueTask<IResult?>>)ValueTaskTestAction, "The IResult returned by the Delegate must not be null." },
2264new object[] { (Func<FSharp.Control.FSharpAsync<string>>)FSharpAsyncOfTMethod },
2265new object[] { (Func<FSharp.Control.FSharpAsync<string>>)FSharpAsyncOfTWithYieldMethod },
2266new object[] { (Func<FSharp.Control.FSharpAsync<object>>)FSharpAsyncOfObjectWithYieldMethod }
2354new object[] { (Func<ValueTask>)ValueTaskMethod },
2355new object[] { (Func<ValueTask<FSharp.Core.Unit>>)ValueTaskOfUnitMethod },
2356new object[] { (Func<Task>)TaskMethod },
2357new object[] { (Func<Task<FSharp.Core.Unit>>)TaskOfUnitMethod },
2358new object[] { (Func<FSharp.Control.FSharpAsync<FSharp.Core.Unit>>)FSharpAsyncOfUnitMethod },
2359new object[] { (Func<ValueTask>)ValueTaskWithYieldMethod },
2360new object[] { (Func<Task>)TaskWithYieldMethod},
2361new object[] { (Func<FSharp.Control.FSharpAsync<FSharp.Core.Unit>>)FSharpAsyncOfUnitWithYieldMethod }
2475new object[] { (Func<ValueTask<TodoStruct>>)ValueTaskOfStructMethod },
2476new object[] { (Func<ValueTask<TodoStruct>>)ValueTaskOfStructWithYieldMethod },
2477new object[] { (Func<Task<TodoStruct>>)TaskOfStructMethod },
2478new object[] { (Func<Task<TodoStruct>>)TaskOfStructWithYieldMethod },
2479new object[] { (Func<FSharp.Control.FSharpAsync<TodoStruct>>)FSharpAsyncOfStructMethod },
2480new object[] { (Func<FSharp.Control.FSharpAsync<TodoStruct>>)FSharpAsyncOfStructWithYieldMethod }
2533var @delegate = () => new object();
2545var @delegate = () => "Hello";
2619var @delegate = () => new AddsCustomEndpointMetadataResult();
2632var @delegate = () => Task.FromResult(new AddsCustomEndpointMetadataResult());
2645var @delegate = () => ValueTask.FromResult(new AddsCustomEndpointMetadataResult());
2658var @delegate = () => FSharp.Core.ExtraTopLevelOperators.DefaultAsyncBuilder.Return(new AddsCustomEndpointMetadataResult());
2671var @delegate = () => new CountsDefaultEndpointMetadataResult();
2693var @delegate = () => Task.FromResult(new CountsDefaultEndpointMetadataResult());
2715var @delegate = () => ValueTask.FromResult(new CountsDefaultEndpointMetadataResult());
2737var @delegate = () => FSharp.Core.ExtraTopLevelOperators.DefaultAsyncBuilder.Return(new CountsDefaultEndpointMetadataResult());
Microsoft.AspNetCore.Http.Results.Tests (4)
Microsoft.AspNetCore.HttpLogging.Tests (1)
Microsoft.AspNetCore.Identity.Test (2)
Microsoft.AspNetCore.InternalTesting (7)
Microsoft.AspNetCore.Mvc.Abstractions (9)
Microsoft.AspNetCore.Mvc.Core (29)
Microsoft.AspNetCore.Mvc.Core.Test (1)
Microsoft.AspNetCore.Mvc.Razor (6)
Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation (1)
Microsoft.AspNetCore.Mvc.Razor.Test (1)
Microsoft.AspNetCore.Mvc.RazorPages (6)
Microsoft.AspNetCore.Mvc.RazorPages.Test (3)
Microsoft.AspNetCore.Mvc.TagHelpers (1)
Microsoft.AspNetCore.Mvc.TagHelpers.Test (8)
SelectTagHelperTest.cs (5)
19public static TheoryData<object, Type, Func<object>, NameAndId, string> GeneratesExpectedDataSet
57return new TheoryData<object, Type, Func<object>, NameAndId, string>
167Func<object> modelAccessor,
256Func<object> modelAccessor,
436Func<object> modelAccessor,
Microsoft.AspNetCore.Mvc.Testing (6)
Microsoft.AspNetCore.Mvc.ViewFeatures (5)
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (2)
Microsoft.AspNetCore.OutputCaching.StackExchangeRedis (2)
Microsoft.AspNetCore.Owin (12)
OwinEnvironment.cs (10)
329public FeatureMap(Type featureInterface, Func<object, object> getter, Func<object> defaultFactory)
352public FeatureMap(Type featureInterface, Func<object, object> getter, Func<object> defaultFactory, Action<object, object> setter)
365public FeatureMap(Type featureInterface, Func<object, object> getter, Func<object> defaultFactory, Action<object, object> setter, Func<object> featureFactory)
377private Func<object> DefaultFactory { get; set; }
378private Func<object> FeatureFactory { get; set; }
443public FeatureMap(Func<TFeature, object> getter, Func<object> defaultFactory)
464public FeatureMap(Func<TFeature, object> getter, Func<object> defaultFactory, Action<TFeature, object> setter)
476public FeatureMap(Func<TFeature, object> getter, Func<object> defaultFactory, Action<TFeature, object> setter, Func<TFeature> featureFactory)
Microsoft.AspNetCore.RateLimiting.Tests (3)
Microsoft.AspNetCore.Razor.Runtime (11)
Microsoft.AspNetCore.Razor.Runtime.Test (5)
Microsoft.AspNetCore.Rewrite (5)
Microsoft.AspNetCore.Routing (4)
Microsoft.AspNetCore.Routing.Tests (1)
Microsoft.AspNetCore.Server.HttpSys (2)
Microsoft.AspNetCore.Server.IntegrationTesting (1)
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (3)
Microsoft.AspNetCore.Server.Kestrel.Tests (1)
Microsoft.AspNetCore.Server.Kestrel.Transport.NamedPipes (1)
Microsoft.AspNetCore.Server.Kestrel.Transport.Quic.Tests (3)
Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets (2)
Microsoft.AspNetCore.Session (6)
Microsoft.AspNetCore.Shared.Tests (7)
Microsoft.AspNetCore.SignalR.Client.Core (4)
Microsoft.AspNetCore.SignalR.Client.Tests (18)
Microsoft.AspNetCore.SignalR.StackExchangeRedis.Tests (5)
Microsoft.AspNetCore.SignalR.Tests (10)
Microsoft.AspNetCore.SpaServices.Extensions (1)
Microsoft.AspNetCore.TestHost (10)
Microsoft.AspNetCore.TestHost.Tests (3)
Microsoft.AspNetCore.WebSockets.Tests (2)
Microsoft.AspNetCore.WebUtilities (6)
Microsoft.Build (20)
Microsoft.Build.CommandLine.UnitTests (2)
Microsoft.Build.Engine.OM.UnitTests (17)
Microsoft.Build.Engine.UnitTests (2)
Microsoft.Build.Tasks.Core (19)
Microsoft.Build.UnitTests.Shared (12)
Microsoft.Build.Utilities.Core (12)
Microsoft.CSharp (1)
Microsoft.DotNet.Build.Tasks.Feed.Tests (1)
Microsoft.DotNet.Helix.Sdk (4)
Microsoft.DotNet.Helix.Sdk.Tests (2)
Microsoft.DotNet.RemoteExecutor (3)
Microsoft.DotNet.VersionTools.Tests (1)
Microsoft.DotNet.XUnitAssert.Tests (8)
Microsoft.DotNet.XUnitExtensions (3)
Microsoft.Extensions.Caching.MicroBenchmarks (4)
Microsoft.Extensions.Caching.StackExchangeRedis (2)
Microsoft.Extensions.Caching.StackExchangeRedis.Tests (1)
Microsoft.Extensions.Configuration.Binder (2)
Microsoft.Extensions.DependencyModel (2)
Microsoft.Extensions.Diagnostics.HealthChecks (4)
Microsoft.Extensions.FileProviders.Physical (2)
Microsoft.Extensions.Hosting (4)
Microsoft.Extensions.Http (5)
Microsoft.Extensions.Http.Polly.Tests (1)
Microsoft.Extensions.ObjectPool (1)
Microsoft.Extensions.Options (2)
Microsoft.Extensions.Primitives (4)
Microsoft.Extensions.WebEncoders (1)
MSBuild (13)
MSBuildTaskHost (12)
mscorlib (1)
Mvc.Api.Analyzers.Test (1)
netstandard (1)
PresentationCore (6)
PresentationFramework (21)
ScenarioTests.Common.Tests (1)
SimpleWebSiteWithWebApplicationBuilderException (1)
Sockets.BindTests (2)
Sockets.FunctionalTests (7)
Swaggatherer (7)
System.ComponentModel.Annotations (5)
System.ComponentModel.Composition (16)
System.Composition.Hosting (3)
System.Composition.Runtime (3)
System.Configuration.ConfigurationManager (1)
System.Core (1)
System.Diagnostics.DiagnosticSource (51)
System\Diagnostics\Metrics\Meter.cs (19)
207public ObservableUpDownCounter<T> CreateObservableUpDownCounter<T>(string name, Func<T> observeValue, string? unit = null, string? description = null) where T : struct =>
221public ObservableUpDownCounter<T> CreateObservableUpDownCounter<T>(string name, Func<T> observeValue, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) where T : struct =>
235public ObservableUpDownCounter<T> CreateObservableUpDownCounter<T>(string name, Func<Measurement<T>> observeValue, string? unit = null, string? description = null) where T : struct =>
249public ObservableUpDownCounter<T> CreateObservableUpDownCounter<T>(string name, Func<Measurement<T>> observeValue, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) where T : struct =>
262public ObservableUpDownCounter<T> CreateObservableUpDownCounter<T>(string name, Func<IEnumerable<Measurement<T>>> observeValues, string? unit = null, string? description = null) where T : struct =>
276public ObservableUpDownCounter<T> CreateObservableUpDownCounter<T>(string name, Func<IEnumerable<Measurement<T>>> observeValues, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) where T : struct =>
289public ObservableCounter<T> CreateObservableCounter<T>(string name, Func<T> observeValue, string? unit = null, string? description = null) where T : struct =>
303public ObservableCounter<T> CreateObservableCounter<T>(string name, Func<T> observeValue, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) where T : struct =>
316public ObservableCounter<T> CreateObservableCounter<T>(string name, Func<Measurement<T>> observeValue, string? unit = null, string? description = null) where T : struct =>
330public ObservableCounter<T> CreateObservableCounter<T>(string name, Func<Measurement<T>> observeValue, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) where T : struct =>
344public ObservableCounter<T> CreateObservableCounter<T>(string name, Func<IEnumerable<Measurement<T>>> observeValues, string? unit = null, string? description = null) where T : struct =>
358public ObservableCounter<T> CreateObservableCounter<T>(string name, Func<IEnumerable<Measurement<T>>> observeValues, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) where T : struct =>
368public ObservableGauge<T> CreateObservableGauge<T>(string name, Func<T> observeValue, string? unit = null, string? description = null) where T : struct =>
379public ObservableGauge<T> CreateObservableGauge<T>(string name, Func<T> observeValue, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) where T : struct =>
389public ObservableGauge<T> CreateObservableGauge<T>(string name, Func<Measurement<T>> observeValue, string? unit = null, string? description = null) where T : struct =>
400public ObservableGauge<T> CreateObservableGauge<T>(string name, Func<Measurement<T>> observeValue, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) where T : struct =>
410public ObservableGauge<T> CreateObservableGauge<T>(string name, Func<IEnumerable<Measurement<T>>> observeValues, string? unit = null, string? description = null) where T : struct =>
421public ObservableGauge<T> CreateObservableGauge<T>(string name, Func<IEnumerable<Measurement<T>>> observeValues, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) where T : struct =>
485private Instrument GetOrCreateInstrument<T>(Type instrumentType, string name, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags, Func<Instrument> instrumentCreator)
System\Diagnostics\Metrics\ObservableCounter.cs (6)
20internal ObservableCounter(Meter meter, string name, Func<T> observeValue, string? unit, string? description) : this(meter, name, observeValue, unit, description, tags: null)
24internal ObservableCounter(Meter meter, string name, Func<T> observeValue, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) : base(meter, name, unit, description, tags)
30internal ObservableCounter(Meter meter, string name, Func<Measurement<T>> observeValue, string? unit, string? description) : this(meter, name, observeValue, unit, description, tags: null)
34internal ObservableCounter(Meter meter, string name, Func<Measurement<T>> observeValue, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) : base(meter, name, unit, description, tags)
40internal ObservableCounter(Meter meter, string name, Func<IEnumerable<Measurement<T>>> observeValues, string? unit, string? description) : this(meter, name, observeValues, unit, description, tags: null)
44internal ObservableCounter(Meter meter, string name, Func<IEnumerable<Measurement<T>>> observeValues, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) : base(meter, name, unit, description, tags)
System\Diagnostics\Metrics\ObservableGauge.cs (6)
20internal ObservableGauge(Meter meter, string name, Func<T> observeValue, string? unit, string? description) : this(meter, name, observeValue, unit, description, tags: null)
24internal ObservableGauge(Meter meter, string name, Func<T> observeValue, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) : base(meter, name, unit, description, tags)
30internal ObservableGauge(Meter meter, string name, Func<Measurement<T>> observeValue, string? unit, string? description) : this(meter, name, observeValue, unit, description, tags: null)
34internal ObservableGauge(Meter meter, string name, Func<Measurement<T>> observeValue, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) : base(meter, name, unit, description, tags)
40internal ObservableGauge(Meter meter, string name, Func<IEnumerable<Measurement<T>>> observeValues, string? unit, string? description) : this(meter, name, observeValues, unit, description, tags: null)
44internal ObservableGauge(Meter meter, string name, Func<IEnumerable<Measurement<T>>> observeValues, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) : base(meter, name, unit, description, tags)
System\Diagnostics\Metrics\ObservableUpDownCounter.cs (6)
20internal ObservableUpDownCounter(Meter meter, string name, Func<T> observeValue, string? unit, string? description) : this(meter, name, observeValue, unit, description, tags: null)
24internal ObservableUpDownCounter(Meter meter, string name, Func<T> observeValue, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) : base(meter, name, unit, description, tags)
30internal ObservableUpDownCounter(Meter meter, string name, Func<Measurement<T>> observeValue, string? unit, string? description) : this(meter, name, observeValue, unit, description, tags: null)
34internal ObservableUpDownCounter(Meter meter, string name, Func<Measurement<T>> observeValue, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) : base(meter, name, unit, description, tags)
40internal ObservableUpDownCounter(Meter meter, string name, Func<IEnumerable<Measurement<T>>> observeValues, string? unit, string? description) : this(meter, name, observeValues, unit, description, tags: null)
44internal ObservableUpDownCounter(Meter meter, string name, Func<IEnumerable<Measurement<T>>> observeValues, string? unit, string? description, IEnumerable<KeyValuePair<string, object?>>? tags) : base(meter, name, unit, description, tags)
System.Linq.Expressions (8)
System.Linq.Parallel (3)
System.Linq.Queryable (5)
System.Net.Http (9)
System.Net.Quic (2)
System.Net.Security (2)
System.Private.CoreLib (65)
src\libraries\System.Private.CoreLib\src\System\Threading\LazyInitializer.cs (11)
81/// <param name="valueFactory">The <see cref="Func{T}"/> invoked to initialize the
102public static T EnsureInitialized<T>([NotNull] ref T? target, Func<T> valueFactory) where T : class =>
112private static T EnsureInitializedCore<T>([NotNull] ref T? target, Func<T> valueFactory) where T : class
195/// <param name="valueFactory">The <see cref="Func{T}"/> invoked to initialize the
198public static T EnsureInitialized<T>([AllowNull] ref T target, ref bool initialized, [NotNullIfNotNull(nameof(syncLock))] ref object? syncLock, Func<T> valueFactory)
219/// The <see cref="Func{T}"/> to invoke in order to produce the lazily-initialized value.
222private static T EnsureInitializedCore<T>([AllowNull] ref T target, ref bool initialized, [NotNull] ref object? syncLock, Func<T> valueFactory)
245/// <param name="valueFactory">The <see cref="Func{T}"/> invoked to initialize the reference.</param>
247public static T EnsureInitialized<T>([NotNull] ref T? target, [NotNullIfNotNull(nameof(syncLock))] ref object? syncLock, Func<T> valueFactory) where T : class =>
259/// The <see cref="Func{T}"/> to invoke in order to produce the lazily-initialized value.
262private static T EnsureInitializedCore<T>([NotNull] ref T? target, [NotNull] ref object? syncLock, Func<T> valueFactory) where T : class
src\libraries\System.Private.CoreLib\src\System\Threading\Tasks\Future.cs (7)
107public Task(Func<TResult> function)
128public Task(Func<TResult> function, CancellationToken cancellationToken)
152public Task(Func<TResult> function, TaskCreationOptions creationOptions)
179public Task(Func<TResult> function, CancellationToken cancellationToken, TaskCreationOptions creationOptions)
286internal Task(Func<TResult> valueSelector, Task? parent, CancellationToken cancellationToken,
310internal static Task<TResult> StartNew(Task? parent, Func<TResult> function, CancellationToken cancellationToken,
488if (m_action is Func<TResult> func)
System.Private.DataContractSerialization (5)
System.Private.Xml (3)
System.Reflection.Metadata (3)
System.Reflection.MetadataLoadContext (5)
System.Runtime (1)
System.Runtime.InteropServices.JavaScript (2)
System.Security.Claims (2)
System.Security.Cryptography (4)
System.Security.Principal.Windows (3)
System.ServiceModel.Http (3)
System.ServiceModel.Primitives (12)
System.Text.Json (33)
System.Text.RegularExpressions (1)
System.Text.RegularExpressions.Generator (1)
System.Threading.Tasks.Dataflow (1)
System.Threading.Tasks.Parallel (17)
System\Threading\Tasks\Parallel.cs (17)
692Func<TLocal> localInit,
745Func<TLocal> localInit,
809Func<TLocal> localInit,
874Func<TLocal> localInit,
920Func<TLocal>? localInit, Action<TLocal>? localFinally)
1416public static ParallelLoopResult ForEach<TSource, TLocal>(IEnumerable<TSource> source, Func<TLocal> localInit,
1481ParallelOptions parallelOptions, Func<TLocal> localInit,
1535public static ParallelLoopResult ForEach<TSource, TLocal>(IEnumerable<TSource> source, Func<TLocal> localInit,
1599public static ParallelLoopResult ForEach<TSource, TLocal>(IEnumerable<TSource> source, ParallelOptions parallelOptions, Func<TLocal> localInit,
1643Func<TLocal>? localInit, Action<TLocal>? localFinally)
1701Func<TLocal>? localInit, Action<TLocal>? localFinally)
1760Func<TLocal>? localInit, Action<TLocal>? localFinally)
2022Func<TLocal> localInit,
2100Func<TLocal> localInit,
2396Func<TLocal> localInit,
2487Func<TLocal> localInit,
2514Func<TLocal>? localInit,
System.Windows.Controls.Ribbon (4)
System.Windows.Input.Manipulations (7)
System.Xaml (4)
Templates.Blazor.Tests (8)
Templates.Blazor.WebAssembly.Auth.Tests (19)
src\Shared\E2ETesting\WaitAssert.cs (11)
26public static void Equal<T>(this IWebDriver driver, T expected, Func<T> actual)
29public static void NotEqual<T>(this IWebDriver driver, T expected, Func<T> actual)
32public static void True(this IWebDriver driver, Func<bool> actual)
35public static void True(this IWebDriver driver, Func<bool> actual, TimeSpan timeout)
38public static void False(this IWebDriver driver, Func<bool> actual)
41public static void Contains(this IWebDriver driver, string expectedSubstring, Func<string> actualString)
44public static void Collection<T>(this IWebDriver driver, Func<IEnumerable<T>> actualValues, params Action<T>[] elementInspectors)
47public static void Empty(this IWebDriver driver, Func<IEnumerable> actualValues)
50public static void Single(this IWebDriver driver, Func<IEnumerable> actualValues)
56public static TElement Exists<TElement>(this IWebDriver driver, Func<TElement> actual, TimeSpan timeout)
86private static TResult WaitAssertCore<TResult>(IWebDriver driver, Func<TResult> assertion, TimeSpan timeout = default)
Templates.Blazor.WebAssembly.Tests (19)
src\Shared\E2ETesting\WaitAssert.cs (11)
26public static void Equal<T>(this IWebDriver driver, T expected, Func<T> actual)
29public static void NotEqual<T>(this IWebDriver driver, T expected, Func<T> actual)
32public static void True(this IWebDriver driver, Func<bool> actual)
35public static void True(this IWebDriver driver, Func<bool> actual, TimeSpan timeout)
38public static void False(this IWebDriver driver, Func<bool> actual)
41public static void Contains(this IWebDriver driver, string expectedSubstring, Func<string> actualString)
44public static void Collection<T>(this IWebDriver driver, Func<IEnumerable<T>> actualValues, params Action<T>[] elementInspectors)
47public static void Empty(this IWebDriver driver, Func<IEnumerable> actualValues)
50public static void Single(this IWebDriver driver, Func<IEnumerable> actualValues)
56public static TElement Exists<TElement>(this IWebDriver driver, Func<TElement> actual, TimeSpan timeout)
86private static TResult WaitAssertCore<TResult>(IWebDriver driver, Func<TResult> assertion, TimeSpan timeout = default)
Templates.Mvc.Tests (19)
src\Shared\E2ETesting\WaitAssert.cs (11)
26public static void Equal<T>(this IWebDriver driver, T expected, Func<T> actual)
29public static void NotEqual<T>(this IWebDriver driver, T expected, Func<T> actual)
32public static void True(this IWebDriver driver, Func<bool> actual)
35public static void True(this IWebDriver driver, Func<bool> actual, TimeSpan timeout)
38public static void False(this IWebDriver driver, Func<bool> actual)
41public static void Contains(this IWebDriver driver, string expectedSubstring, Func<string> actualString)
44public static void Collection<T>(this IWebDriver driver, Func<IEnumerable<T>> actualValues, params Action<T>[] elementInspectors)
47public static void Empty(this IWebDriver driver, Func<IEnumerable> actualValues)
50public static void Single(this IWebDriver driver, Func<IEnumerable> actualValues)
56public static TElement Exists<TElement>(this IWebDriver driver, Func<TElement> actual, TimeSpan timeout)
86private static TResult WaitAssertCore<TResult>(IWebDriver driver, Func<TResult> assertion, TimeSpan timeout = default)
Templates.Tests (19)
src\Shared\E2ETesting\WaitAssert.cs (11)
26public static void Equal<T>(this IWebDriver driver, T expected, Func<T> actual)
29public static void NotEqual<T>(this IWebDriver driver, T expected, Func<T> actual)
32public static void True(this IWebDriver driver, Func<bool> actual)
35public static void True(this IWebDriver driver, Func<bool> actual, TimeSpan timeout)
38public static void False(this IWebDriver driver, Func<bool> actual)
41public static void Contains(this IWebDriver driver, string expectedSubstring, Func<string> actualString)
44public static void Collection<T>(this IWebDriver driver, Func<IEnumerable<T>> actualValues, params Action<T>[] elementInspectors)
47public static void Empty(this IWebDriver driver, Func<IEnumerable> actualValues)
50public static void Single(this IWebDriver driver, Func<IEnumerable> actualValues)
56public static TElement Exists<TElement>(this IWebDriver driver, Func<TElement> actual, TimeSpan timeout)
86private static TResult WaitAssertCore<TResult>(IWebDriver driver, Func<TResult> assertion, TimeSpan timeout = default)
UnitTests.Common (11)
Wasm.Performance.ConsoleHost (10)
WasmAppBuilder (1)
XmlFileLogger (1)
xunit.assert (31)
xunit.console (3)