IRI.Maptor.Core.Common
4.0.1
dotnet add package IRI.Maptor.Core.Common --version 4.0.1
NuGet\Install-Package IRI.Maptor.Core.Common -Version 4.0.1
<PackageReference Include="IRI.Maptor.Core.Common" Version="4.0.1" />
<PackageVersion Include="IRI.Maptor.Core.Common" Version="4.0.1" />
<PackageReference Include="IRI.Maptor.Core.Common" />
paket add IRI.Maptor.Core.Common --version 4.0.1
#r "nuget: IRI.Maptor.Core.Common, 4.0.1"
#:package IRI.Maptor.Core.Common@4.0.1
#addin nuget:?package=IRI.Maptor.Core.Common&version=4.0.1
#tool nuget:?package=IRI.Maptor.Core.Common&version=4.0.1
IRI.Maptor.Core.Common
The foundational package of the Maptor GIS stack. It provides the core geometric primitives, abstractions, data structures, mathematics, unit types, and helper utilities that every other IRI.Maptor.* package builds on.
Installation
dotnet add package IRI.Maptor.Core.Common
Features
- Geometric primitives:
Point,PointM,PointZ,PointZM,BoundingBox,LineSegment,PointCollection - Core abstractions, enums, attributes, and JSON converters shared across the stack
DataSourceKind(IRI.Maptor.Core.Common.Enums): every format a layer can be read from or exported to, each with its category and file-dialog filter (DataSourceKindInfo), includingFileGdb(a folder, no filter),GeoParquet,Grd(Esri ASCII grid) and the export-onlySvgandEps- Domain exceptions (
IRI.Maptor.Core.Common.Exceptions) that carry a resource key for the user's message and an API result type, e.g.MaptorNoSaveAddressException(a layer's changes have nowhere to be saved; they stay pending) - Data structures: binary heaps (min/max), binary search tree, red-black tree, interval tree, order-statistic tree, B-tree, disjoint set, sort algorithms
- Mathematics:
Matrix,Vector, and eigenvalue/eigenvector computation (IRI.Maptor.Core.Common.Mathematics), plus statistics models - Linear and angular unit types with conversions:
Meter,Foot,Mile,Yard,Inch,Rod,Chain,Degree,Radian,Grade(IRI.Maptor.Core.Common.Metrics) - Encodings: Base64 URL encoding and Persian DOS code page conversion
- Helpers for I/O, JSON/XML, HTTP transport, hex strings, zip archives, randomness, and secure strings
- Extension methods for common BCL types (strings, numbers, dates, collections)
- Response/contract models for external map services (Google, Bing, Here, Mapzen)
Usage
Working with bounding boxes:
using IRI.Maptor.Core.Common.Primitives;
var bbox = new BoundingBox(xMin: 50.8, yMin: 35.5, xMax: 51.6, yMax: 35.9);
Console.WriteLine(bbox.Center); // (51.2, 35.7)
Console.WriteLine(bbox.Width); // 0.8
var merged = bbox.Add(new BoundingBox(50.0, 35.0, 51.0, 36.0));
var grown = bbox.Expand(1.1); // scale around the center
Converting between linear units:
using IRI.Maptor.Core.Common.Metrics;
var distance = new Meter(1609.344);
var miles = (Mile)distance; // explicit conversion between unit types
Basic linear algebra:
using IRI.Maptor.Core.Common.Mathematics;
var m = new Matrix(new double[,] { { 1, 2 }, { 3, 4 } });
Describing a layer's fields (Field): the logical type and the allowed values travel with every field.
using IRI.Maptor.Core.Common.Primitives;
List<Field> fields = Field.GetFields<Pipe>(); // from [Field(...)] and domain attributes
FieldDataType type = fields[0].ResolveDataType(); // DataType, else what TypeFullName names, else Unknown
FieldDomain? domain = fields[0].Domain; // values (+ codes) from a FieldDomainAttribute or [Field(AllowedValues = ...)]
bool allowed = domain?.Contains(4) == true; // numbers compare by value whatever their CLR type
TypeFullName keeps the producer's native name (a .NET type name, or an SQL type name in the SQL Server
schema readers); read the type with ResolveDataType(). Applications attach their own domains by deriving
from FieldDomainAttribute.
See also
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
| .NET Core | netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.1 is compatible. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.1
- System.Net.Http.Json (>= 9.0.7)
- System.Text.Json (>= 9.0.7)
NuGet packages (21)
Showing the top 5 NuGet packages that depend on IRI.Maptor.Core.Common:
| Package | Downloads |
|---|---|
|
IRI.Maptor.Core.Graph
A .NET standard library containing primitive graph structures and algorithms |
|
|
IRI.Maptor.Core.SpatialReferenceSystem
A .NET standard library to transform various spatial reference systems |
|
|
IRI.Maptor.Core.Spatial
A .NET standard library to work with spatial types, structures and algorithms (GeoJson, Geometry, KdTree, RTree, Delaunay, Simplification, etc.) |
|
|
IRI.Maptor.Core.Ogc
A .NET standard library containing OGC standards such as SFA, SLD, WFS, WMS, GML, KML |
|
|
IRI.Maptor.Core.ShapefileFormat
A .NET standard library to read/write shapefile (*.shp, *.shx, *.dbf, *.prj) |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 4.0.1 | 642 | 12/1/2026 |
| 4.0.1-alpha | 600 | 12/1/2026 |
| 4.0.0 | 632 | 12/1/2026 |
| 4.0.0-alpha | 591 | 12/1/2026 |
| 3.0.0 | 879 | 8/23/2026 |
| 3.0.0-alpha | 817 | 8/22/2026 |