box property
Box
box
A bounding box with coordinate values as a view backed by this
.
Supported values combinations:
- minX, minY, maxX, maxY
- minX, minY, minZ, maxX, maxY, maxZ
- minX, minY, minZ, minM, maxX, maxY, maxZ, maxM
Or for geographic coordinates:
- west, south, east, north
- west, south, minElev, east, north, maxElev
- west, south, minElev, minM, east, north, maxElev, maxM
See Box.view for more information.
Examples:
// a 2D box (x: 10.0 .. 15.0, y: 20.0 .. 25.0)
[10.0, 20.0, 15.0, 25.0].box;
// a 3D box (x: 10.0 .. 15.0, y: 20.0 .. 25.0, z: 30.0 .. 35.0)
[10.0, 20.0, 30.0, 15.0, 25.0, 35.0].box;
// a measured 3D box
// (x: 10.0 .. 15.0, y: 20.0 .. 25.0, z: 30.0 .. 35.0, m: 40.0 .. 45.0)
[10.0, 20.0, 30.0, 40.0, 15.0, 25.0, 35.0, 45.0].box;
Implementation
Box get box => Box.view(this, type: Coords.fromDimension(length ~/ 2));