< Summary

Class:Azure.Core.GeoJson.GeoLine
Assembly:Azure.Core.Experimental
File(s):C:\Git\azure-sdk-for-net\sdk\core\Azure.Core.Experimental\src\Spatial\GeoLine.cs
Covered lines:4
Uncovered lines:2
Coverable lines:6
Total lines:38
Line coverage:66.6% (4 of 6)
Covered branches:0
Total branches:0

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor(...)-0%100%
.ctor(...)-100%100%
get_Positions()-100%100%

File(s)

C:\Git\azure-sdk-for-net\sdk\core\Azure.Core.Experimental\src\Spatial\GeoLine.cs

#LineLine coverage
 1// Copyright (c) Microsoft Corporation. All rights reserved.
 2// Licensed under the MIT License.
 3
 4using System.Collections.Generic;
 5using System.Linq;
 6
 7namespace Azure.Core.GeoJson
 8{
 9    /// <summary>
 10    /// Represents a line geometry that consists of multiple coordinates.
 11    /// </summary>
 12    public sealed class GeoLine : GeoObject
 13    {
 14        /// <summary>
 15        /// Initializes new instance of <see cref="GeoLine"/>.
 16        /// </summary>
 17        /// <param name="coordinates">The collection of <see cref="GeoPosition"/> that make up the line.</param>
 018        public GeoLine(IEnumerable<GeoPosition> coordinates): this(coordinates, null, DefaultProperties)
 19        {
 020        }
 21
 22        /// <summary>
 23        /// Initializes new instance of <see cref="GeoLine"/>.
 24        /// </summary>
 25        /// <param name="coordinates">The collection of <see cref="GeoPosition"/> that make up the line.</param>
 26        /// <param name="boundingBox">The <see cref="GeoBoundingBox"/> to use.</param>
 27        /// <param name="additionalProperties">The set of additional properties associated with the <see cref="GeoObject
 14428        public GeoLine(IEnumerable<GeoPosition> coordinates, GeoBoundingBox? boundingBox, IReadOnlyDictionary<string, ob
 29        {
 14430            Positions = coordinates.ToArray();
 14431        }
 32
 33        /// <summary>
 34        /// Gets the list of <see cref="GeoPosition"/> that compose this line.
 35        /// </summary>
 14836        public IReadOnlyList<GeoPosition> Positions { get; }
 37    }
 38}