< Summary

Class:Itinero.Instructions.RouteAndBaseInstructions
Assembly:Itinero.Instructions
File(s):/home/runner/work/routing2/routing2/src/Itinero.Instructions/IRouteAndBaseInstructions.cs
Covered lines:10
Uncovered lines:0
Coverable lines:10
Total lines:44
Line coverage:100% (10 of 10)
Covered branches:0
Total branches:0
Tag:224_14471318300

Metrics

MethodBranch coverage Cyclomatic complexity Line coverage
.ctor(...)100%1100%
get_Route()100%1100%
get_BaseInstructions()100%1100%
get_Languages()100%1100%

File(s)

/home/runner/work/routing2/routing2/src/Itinero.Instructions/IRouteAndBaseInstructions.cs

#LineLine coverage
 1using System.Collections.Generic;
 2using Itinero.Instructions.ToText;
 3using Itinero.Instructions.Types;
 4using Itinero.Routes;
 5
 6namespace Itinero.Instructions;
 7
 8/// <summary>
 9/// Abstract representation of a route and associated base instructions.
 10/// </summary>
 11public interface IRouteAndBaseInstructions
 12{
 13    /// <summary>
 14    /// The route.
 15    /// </summary>
 16    Route Route { get; }
 17
 18    /// <summary>
 19    /// The base instructions.
 20    /// </summary>
 21    IReadOnlyList<BaseInstruction> BaseInstructions { get; }
 22
 23    /// <summary>
 24    /// The supported languages.
 25    /// </summary>
 26    IReadOnlyDictionary<string, IInstructionToText> Languages { get; }
 27}
 28
 29internal class RouteAndBaseInstructions : IRouteAndBaseInstructions
 30{
 231    internal RouteAndBaseInstructions(Route route, IReadOnlyList<BaseInstruction> baseInstructions,
 232        IReadOnlyDictionary<string, IInstructionToText> languages)
 233    {
 234        this.Route = route;
 235        this.BaseInstructions = baseInstructions;
 236        this.Languages = languages;
 237    }
 38
 239    public Route Route { get; }
 40
 241    public IReadOnlyList<BaseInstruction> BaseInstructions { get; }
 42
 243    public IReadOnlyDictionary<string, IInstructionToText> Languages { get; }
 44}