geometry constant
The Well-known binary (WKB) format for geometries.
Use encoder
and encoder
methods of the format instance to access an
encoder or an decoder for WKB.
Supported geometry types and their "WKB integer codes" for different coordinate types:
Geometry | 2D | Z | M | ZM |
---|---|---|---|---|
point |
0001 | 1001 | 2001 | 3001 |
lineString |
0002 | 1002 | 2002 | 3002 |
polygon |
0003 | 1003 | 2003 | 3003 |
multiPoint |
0004 | 1004 | 2004 | 3004 |
multiLineString |
0005 | 1005 | 2005 | 3005 |
multiPolygon |
0006 | 1006 | 2006 | 3006 |
geometryCollection |
0007 | 1007 | 2007 | 3007 |
For WKB binary data encoding, the Endian.little
(NDR) byte order is used
by default, however when accessing an encoder it's possible to specify
also the Endian.big
(XDR) byte order.
See also geometryExtended to get a format for the Extended WKB (EWKB).
Implementation
static const BinaryFormat<GeometryContent> geometry =
_WkbGeometryBinaryFormat(flavor: WkbFlavor.standard);