locationtech / jts

The JTS Topology Suite is a Java library for creating and manipulating vector geometry.
Other
1.95k stars 440 forks source link

Expose GeometryOverlay `isOverlayNG` flag #1034

Open micycle1 opened 8 months ago

micycle1 commented 8 months ago

The GeometryOverlay class has a flag for switching overlay engine between the original algorithm and OverlayNG.

However this flag is only configurable via the system property "jts.overlay" , which is rather awkward since one cannot change it during runtime and it won't even work if the class happens to be loaded before the user wants to set it (I've had to resort to reflection since System.setProperty("jts-overlay", "ng") is not working).

I think it should be exposed in some way, making the class public and either the setOverlayImpl() method public or the isOverlayNG flag public for instance.