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
- markdown: Initializes a new instance of the <xref href="PolylineAlgorithm.Abstraction.AbstractPolylineDecoder%602" data-throw-if-not-resolved="false"></xref> class with default encoding options.
description: An <xref href="System.Collections.Generic.IEnumerable%601" data-throw-if-not-resolved="false"></xref> of <code class="typeparamref">TCoordinate</code> representing the decoded latitude and longitude pairs.
description: Thrown when <code class="paramref">polyline</code> is <a href="https://learn.microsoft.com/dotnet/csharp/language-reference/keywords/null">null</a>.
description: A <xref href="System.Threading.CancellationToken" data-throw-if-not-resolved="false"></xref> that can be used to cancel the decoding operation.
148
+
optional: true
185
149
- h4: Returns
186
150
- parameters:
187
151
- type:
@@ -203,15 +167,15 @@ body:
203
167
description: Thrown when <code class="paramref">polyline</code> is empty.
description: A <xref href="System.ReadOnlyMemory%601" data-throw-if-not-resolved="false"></xref> of <xref href="System.Char" data-throw-if-not-resolved="false"></xref> representing the encoded polyline characters.
- markdown: Encodes a collection of <code class="typeparamref">TCoordinate</code> instances into an encoded <code class="typeparamref">TPolyline</code> string.
138
138
- code: >-
139
139
[SuppressMessage("Design", "MA0051:Method is too long", Justification = "Method contains local methods. Actual method only 55 lines.")]
140
140
141
-
public TPolyline Encode(ReadOnlySpan<TCoordinate> coordinates)
141
+
public TPolyline Encode(ReadOnlySpan<TCoordinate> coordinates, CancellationToken cancellationToken = default)
142
142
- h4: Parameters
143
143
- parameters:
144
144
- name: coordinates
@@ -149,6 +149,12 @@ body:
149
149
- TCoordinate
150
150
- '>'
151
151
description: The collection of <code class="typeparamref">TCoordinate</code> objects to encode.
description: A <xref href="System.Threading.CancellationToken" data-throw-if-not-resolved="false"></xref> that can be used to cancel the encoding operation.
157
+
optional: true
152
158
- h4: Returns
153
159
- parameters:
154
160
- type:
@@ -170,7 +176,7 @@ body:
170
176
description: Thrown when the internal encoding buffer cannot accommodate the encoded value.
description: An <xref href="System.Collections.Generic.IEnumerable%601" data-throw-if-not-resolved="false"></xref> of <code class="typeparamref">TCoordinate</code> representing the decoded latitude and longitude pairs.
71
+
description: >-
72
+
An <xref href="System.Collections.Generic.IEnumerable%601" data-throw-if-not-resolved="false"></xref> of <code class="typeparamref">TValue</code> representing the decoded
73
+
74
+
latitude/longitude pairs (or equivalent coordinates) in the same order they were encoded.
75
+
- h4: Remarks
76
+
- markdown: >-
77
+
Implementations commonly follow the Google Encoded Polyline Algorithm Format, but this interface
78
+
79
+
does not mandate a specific encoding. Consumers should rely on a concrete decoder's documentation
0 commit comments