Skip to content

Commit

Permalink
Added default ParrallelAsyncOptions
Browse files Browse the repository at this point in the history
  • Loading branch information
Simnico99 committed Oct 7, 2022
1 parent 17413ea commit 498bae4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/ZirconNet.Core/Async/ParallelAsyncOptions.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
namespace ZirconNet.Core.Async;
public readonly struct ParallelAsyncOptions
{
private static ParallelAsyncOptions? _internalDefaultStuct;
public static ParallelAsyncOptions Default => _internalDefaultStuct ??= new();
#if NET5_0_OR_GREATER
public CancellationToken CancellationToken { get; init; } = default;
public int MaxDegreeOfParallelism { get; init; } = -1;
Expand Down

0 comments on commit 498bae4

Please sign in to comment.