You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Value precision and rounding rules (for example 1e-5 for 5-decimal precision).
57
57
- Value ordering and whether altitude or additional dimensions are supported.
58
58
- Thread-safety guarantees: whether instances are safe to reuse concurrently or must be instantiated per-call.
59
-
- Implementations are encouraged to be memory-efficient; the API accepts a <xref href="System.ReadOnlySpan%601" data-throw-if-not-resolved="false"></xref>
60
-
to avoid forced allocations when callers already have contiguous memory.
The collection of <code class="typeparamref">TValue</code> instances to encode into a polyline.
81
+
The sequence of <code class="typeparamref">TValue</code> instances to encode into a polyline.
84
82
85
-
The span may be empty; implementations should return an appropriate empty encoded representation
83
+
The sequence may be empty; implementations should return an appropriate empty encoded representation
86
84
87
85
(for example an empty string or an empty memory slice) rather than <a href="https://learn.microsoft.com/dotnet/csharp/language-reference/keywords/null">null</a>.
86
+
87
+
Must not be <a href="https://learn.microsoft.com/dotnet/csharp/language-reference/keywords/null">null</a>.
88
88
- name: options
89
89
type:
90
90
- text: PolylineEncodingOptions
@@ -135,6 +135,10 @@ body:
135
135
variants can still implement this interface by materializing the final encoded result.
description: Thrown if <code class="paramref">coordinates</code> is <a href="https://learn.microsoft.com/dotnet/csharp/language-reference/keywords/null">null</a>.
description: Thrown when <code class="paramref">options</code> is <a href="https://learn.microsoft.com/dotnet/csharp/language-reference/keywords/null">null</a>.
Encodes a collection of <code class="typeparamref">TValue</code> instances into an encoded
105
105
106
106
<code class="typeparamref">TPolyline</code>.
107
-
- code: public TPolyline Encode(ReadOnlySpan<TValue> coordinates, CancellationToken cancellationToken = default)
107
+
- code: >-
108
+
[SuppressMessage("Design", "CA1062:Validate arguments of public methods", Justification = "Null is verified before use via ExceptionGuard.ThrowArgumentNull, which is annotated [DoesNotReturn]. CA1062 does not recognise custom [DoesNotReturn] helpers as null guards.")]
109
+
110
+
public TPolyline Encode(IEnumerable<TValue> coordinates, CancellationToken cancellationToken = default)
description: Thrown when <code class="paramref">coordinates</code> is <a href="https://learn.microsoft.com/dotnet/csharp/language-reference/keywords/null">null</a>.
Encodes a collection of <code class="typeparamref">TValue</code> instances into an encoded
151
154
@@ -154,13 +157,16 @@ body:
154
157
delta baseline. Use this overload to encode large sequences in independent chunks that can be
155
158
156
159
concatenated into a single valid polyline.
157
-
- code: public TPolyline Encode(ReadOnlySpan<TValue> coordinates, PolylineEncodingOptions<TValue>? options, CancellationToken cancellationToken)
160
+
- code: >-
161
+
[SuppressMessage("Design", "CA1062:Validate arguments of public methods", Justification = "Null is verified before use via ExceptionGuard.ThrowArgumentNull, which is annotated [DoesNotReturn]. CA1062 does not recognise custom [DoesNotReturn] helpers as null guards.")]
162
+
163
+
public TPolyline Encode(IEnumerable<TValue> coordinates, PolylineEncodingOptions<TValue>? options, CancellationToken cancellationToken)
description: Thrown when <code class="paramref">coordinates</code> is <a href="https://learn.microsoft.com/dotnet/csharp/language-reference/keywords/null">null</a>.
Copy file name to clipboardExpand all lines: api-reference/0.0/PolylineAlgorithm.PolylineEncodingOptions-1.yml
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -44,7 +44,7 @@ body:
44
44
- markdown: >-
45
45
Pass an instance of this class to the chunked
46
46
47
-
<xref href="PolylineAlgorithm.Abstraction.IPolylineEncoder%602.Encode(System.ReadOnlySpan%7b%600%7d%2cPolylineAlgorithm.PolylineEncodingOptions%7b%600%7d%2cSystem.Threading.CancellationToken)" data-throw-if-not-resolved="false"></xref> overload to control
47
+
<xref href="PolylineAlgorithm.Abstraction.IPolylineEncoder%602.Encode(System.Collections.Generic.IEnumerable%7b%600%7d%2cPolylineAlgorithm.PolylineEncodingOptions%7b%600%7d%2cSystem.Threading.CancellationToken)" data-throw-if-not-resolved="false"></xref> overload to control
48
48
49
49
the delta baseline used at the start of each chunk. When <xref href="PolylineAlgorithm.PolylineEncodingOptions%601.HasPrevious" data-throw-if-not-resolved="false"></xref> is
0 commit comments