Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
DefaultMergeHelper.cs
Go to the documentation of this file.
3
5
6internal sealed class DefaultMergeHelper<TInputOutput, TIgnoreKey> : IMergeHelper<TInputOutput>
7{
9
11
13
15
17
18 private readonly TaskScheduler _taskScheduler;
19
20 private readonly bool _ignoreOutput;
21
51
53 {
54 if (_asyncChannels != null)
55 {
57 }
58 else if (_syncChannels != null)
59 {
61 }
62 else if (_ignoreOutput)
63 {
65 }
66 }
67
72
74 {
75 if (_syncChannels != null)
76 {
77 int num = 0;
78 for (int i = 0; i < _syncChannels.Length; i++)
79 {
80 num += _syncChannels[i].Count;
81 }
82 TInputOutput[] array = new TInputOutput[num];
83 int num2 = 0;
84 for (int j = 0; j < _syncChannels.Length; j++)
85 {
88 }
89 return array;
90 }
93 {
94 list.Add(item);
95 }
96 return list.ToArray();
97 }
98}
readonly PartitionedStream< TInputOutput, TIgnoreKey > _partitions
readonly SynchronousChannel< TInputOutput >[] _syncChannels
readonly IEnumerator< TInputOutput > _channelEnumerator
readonly QueryTaskGroupState _taskGroupState
DefaultMergeHelper(PartitionedStream< TInputOutput, TIgnoreKey > partitions, bool ignoreOutput, ParallelMergeOptions options, TaskScheduler taskScheduler, CancellationState cancellationState, int queryId)
readonly AsynchronousChannel< TInputOutput >[] _asyncChannels
void CopyTo(T[] array, int arrayIndex)