.NET Framework Class Library |
ParallelEnumerable..::.Union<(Of <(TSource>)>) Method (ParallelQuery<(Of <(TSource>)>), IEnumerable<(Of <(TSource>)>)) |
ParallelEnumerable Class See Also Send Feedback |
This Union overload should never be called.
This method is marked as obsolete and always throws NotSupportedException when called.
Namespace:
System.Linq
Assembly:
System.Threading (in System.Threading.dll)
Syntax
Visual Basic (Declaration) |
---|
<ObsoleteAttribute("The second data source of a binary operator must be of type System.Linq.ParallelQuery<T> rather than System.Collections.Generic.IEnumerable<T>. To fix this problem, use the AsParallel() extension method to convert the right data source to System.Linq.ParallelQuery<T>.")> _ Public Shared Function Union(Of TSource) ( _ first As ParallelQuery(Of TSource), _ second As IEnumerable(Of TSource) _ ) As ParallelQuery(Of TSource) |
C# |
---|
[ObsoleteAttribute("The second data source of a binary operator must be of type System.Linq.ParallelQuery<T> rather than System.Collections.Generic.IEnumerable<T>. To fix this problem, use the AsParallel() extension method to convert the right data source to System.Linq.ParallelQuery<T>.")] public static ParallelQuery<TSource> Union<TSource>( ParallelQuery<TSource> first, IEnumerable<TSource> second ) |
Parameters
- first
- Type: System.Linq..::.ParallelQuery<(Of <(TSource>)>)
This parameter is not used.
- second
- Type: System.Collections.Generic..::.IEnumerable<(Of <(TSource>)>)
This parameter is not used.
Type Parameters
- TSource
- This type parameter is not used.
Return Value
This overload always throws a NotSupportedException.Remarks
This overload exists to disallow usage of Union with a left data source of type
ParallelQuery<(Of <(TSource>)>) and a right data source of type IEnumerable<(Of <(T>)>).
Otherwise, the Union operator would appear to be binding to the parallel implementation,
but would in reality bind to sequential implementation.
Exceptions
Exception | Condition |
---|---|
System..::.NotSupportedException | The exception that occurs when this method is called. |