TopoJsonWriterOptions Class

The options of the TopoJSON writer, TopoJson.

public sealed class TopoJsonWriterOptions

Constructors

NameDescription
TopoJsonWriterOptions()

TopoJsonWriterOptions()

public TopoJsonWriterOptions()

No documentation is available.

Properties

NameDescription
IndentedGets or sets a value that indicates whether the JSON is indented. The default is false.
QuantizationGets or sets the number of distinct values of each coordinate, such as 10000 or 100000, or null to write the positions as they are. The default is null.

Gets or sets a value that indicates whether the JSON is indented. The default is false.

public bool Indented { get; set; }

Property value

bool

Gets or sets the number of distinct values of each coordinate, such as 10000 or 100000, or null to write the positions as they are. The default is null.

public int? Quantization { get; set; }

Property value

int?

Exceptions

ArgumentOutOfRangeException
The value is less than 2.

Remarks

When it is set, the topology gets a transform: the longitudes and latitudes are rounded to a grid of this many values over the bounds of the features, and the arcs are delta-encoded, which makes the file much smaller. The positions read back are then on that grid, and the consecutive positions that round to the same value are merged.