Releases: brick/geo
0.11.1
0.11.0
0.10.0
💥 Breaking changes
- Minimum PHP version is now
8.1
- interface
GeometryEngine
has a new method:makeValid()
AbstractWKBWriter::setByteOrder()
now accepts aWKBByteOrder
enum instead of aWKBTools::*_ENDIAN
constant- constants
WKBTools::BIG_ENDIAN
andWKBTools::LITTLE_ENDIAN
have been removed - method
WKBTools::checkByteOrder()
has been removed
✨ New features
- New engine method:
GeometryEngine::makeValid()
0.9.0
💥 Breaking changes
- Proxies are now
@internal
and considered an implementation detail. This means that they are no longer part of the public API and can change at any time. This means that you should always type-hint against the base class and not the proxy. Point
constructor now throws an exception when passingNaN
or infinite coordinates.GeometryEngine::pointOnSurface()
now returnsPoint
instead ofGeometry
.
🐛 Bug fixes
Geometry::withSRID()
now properly propagates the SRID to all sub-geometries. Previously, only the top-level geometry was updated.Point
constructor would error when destructuring an associative array.
✨ New features
- New
Projector
API to reproject geometry coordinates. - New method:
Polygon::rings()
- New method:
Geometry::isIdenticalTo()
✨ Improvements
GeometryCollection::geometryN()
is now properly documented with generics.
0.8.1
0.8.0
💥 Breaking changes
Minimum PHP version is now 8.0
.
The global GeometryEngineRegistry
is gone. All convenience methods that rely on the GeometryEngineRegistry
have been removed.
You should now explicitly call the GeometryEngine
, that you can get injected with your dependency injection container.
For example, the following call:
$lineString->length();
Should be replaced with:
$geometryEngine->length($lineString);
Detail of breaking changes
The following class has been removed:
GeometryEngineRegistry
The following method has been added:
GeometryEngine::isRing()
The following method signatures have been changed:
GeometryEngine::boundingPolygons()
The following deprecated methods have been removed:
Curve::isClosed()
Curve::isRing()
Curve::length()
Geometry::boundary()
Geometry::buffer()
Geometry::centroid()
Geometry::contains()
Geometry::convexHull()
Geometry::crosses()
Geometry::difference()
Geometry::disjoint()
Geometry::distance()
Geometry::equals()
Geometry::envelope()
Geometry::intersection()
Geometry::intersects()
Geometry::isSimple()
Geometry::isValid()
Geometry::locateAlong()
Geometry::locateBetween()
Geometry::maxDistance()
Geometry::overlaps()
Geometry::relate()
Geometry::simplify()
Geometry::snapToGrid()
Geometry::symDifference()
Geometry::touches()
Geometry::transform()
Geometry::union()
Geometry::within()
MultiCurve::isClosed()
MultiCurve::length()
MultiSurface::area()
MultiSurface::pointOnSurface()
Point::azimuth()
PolyhedralSurface::boundingPolygons()
PolyhedralSurface::isClosed()
Surface::area()
Surface::pointOnSurface()
The following change only affects you if you implement a custom DatabaseEngine
:
- The signature of
DatabaseEngine::getParameterPlaceholder()
has changed
💥 Non-breaking changes
- The following signatures have changed, but are not a breaking change due to LSP:
DatabaseEngine::getParameterPlaceholder(mixed $parameter): string
GeometryEngine::length(Curve|MultiCurve $g): float
GeometryEngine::area(Surface|MultiSurface $g): float
GeometryEngine::pointOnSurface(Surface|MultiSurface $g): Geometry
🐛 Fixes
- Fixed a potential bug when destructuring associative arrays in Geometry class constructors
0.7.2
🗑️ Deprecations
The GeometryEngineRegistry
class has been deprecated. All convenience methods on Geometry classes that rely on the GeometryEngineRegistry
are deprecated, and will be removed in version 0.8
.
You should now explicitly call the GeometryEngine
, that you can get injected with your dependency injection container.
Deprecated methods:
Curve::isClosed()
Curve::isRing()
Curve::length()
Geometry::boundary()
Geometry::buffer()
Geometry::centroid()
Geometry::contains()
Geometry::convexHull()
Geometry::crosses()
Geometry::difference()
Geometry::disjoint()
Geometry::distance()
Geometry::equals()
Geometry::envelope()
Geometry::intersection()
Geometry::intersects()
Geometry::isSimple()
Geometry::isValid()
Geometry::locateAlong()
Geometry::locateBetween()
Geometry::maxDistance()
Geometry::overlaps()
Geometry::relate()
Geometry::simplify()
Geometry::snapToGrid()
Geometry::symDifference()
Geometry::touches()
Geometry::transform()
Geometry::union()
Geometry::within()
MultiCurve::isClosed()
MultiCurve::length()
MultiSurface::area()
MultiSurface::pointOnSurface()
Point::azimuth()
PolyhedralSurface::boundingPolygons()
PolyhedralSurface::isClosed()
Surface::area()
Surface::pointOnSurface()
0.7.1
0.7.0
💥 Breaking change
The Doctrine mapping types & functions have been moved to a separate package.
If you don't use these, you don't need to do anything to upgrade.
If you use them, just require the brick/geo-doctrine package in addition to brick/geo
.