And.cs 806 B

1234567891011121314151617181920212223
  1. // Licensed to the .NET Foundation under one or more agreements.
  2. // The .NET Foundation licenses this file to you under the MIT License.
  3. // See the LICENSE file in the project root for more information.
  4. using System.Reactive.Joins;
  5. namespace System.Reactive.Linq
  6. {
  7. // REVIEW: Consider moving join patterns to a separate assembly.
  8. public partial class AsyncObservable
  9. {
  10. public static AsyncPattern<TLeft, TRight> And<TLeft, TRight>(this IAsyncObservable<TLeft> left, IAsyncObservable<TRight> right)
  11. {
  12. if (left == null)
  13. throw new ArgumentNullException(nameof(left));
  14. if (right == null)
  15. throw new ArgumentNullException(nameof(right));
  16. return new AsyncPattern<TLeft, TRight>(left, right);
  17. }
  18. }
  19. }