< Summary

Information
Line coverage
0%
Covered lines: 0
Uncovered lines: 3
Coverable lines: 3
Total lines: 31
Line coverage: 0%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
Scheduled(...)100%210%

File(s)

https://raw.githubusercontent.com/sandre58/MyNet/85372080fe102cd9ee155ceab49ae000e7f66103/src/MyNet.Observable/Collections/Extensions/CollectionExtensions.cs

#LineLine coverage
 1// -----------------------------------------------------------------------
 2// <copyright file="CollectionExtensions.cs" company="Stéphane ANDRE">
 3// Copyright (c) Stéphane ANDRE. All rights reserved.
 4// </copyright>
 5// -----------------------------------------------------------------------
 6
 7using System;
 8using System.Reactive.Concurrency;
 9using MyNet.Collections;
 10using MyNet.Observable.Collections;
 11
 12#pragma warning disable IDE0130 // Namespace does not match folder structure
 13namespace MyNet.Observable;
 14#pragma warning restore IDE0130 // Namespace does not match folder structure
 15
 16/// <summary>
 17/// Scheduling helpers for observable range collections.
 18/// </summary>
 19public static class CollectionExtensions
 20{
 21    /// <summary>
 22    /// Wraps an observable range collection so notifications are dispatched on the specified Rx scheduler.
 23    /// </summary>
 24    public static DispatchedObservableCollection<T> Scheduled<T>(this ObservableRangeCollection<T> collection, ISchedule
 25    {
 026        ArgumentNullException.ThrowIfNull(collection);
 027        ArgumentNullException.ThrowIfNull(scheduler);
 028        return new(collection, new SchedulerCollectionEventDispatcher(scheduler));
 29    }
 30}
 31