Optimize point-in-circle (geodesic) calc tracking results of previous results
The Circle shape determines the relationship between another shape (notable a point or rectangle) with itself (e.g. Within, Disjoint, ...). To do this, usually needs to call DistanceCalculator.withinDistance(point, point, distance) one or more times. For the geodesic implementation, the distance calculation is somewhat expensive.
Milestone 1: An idea here is to first use the internal 45-degree rectangle to more quickly calculate if the point is within that. It's in effect an inner-box (versus an outer bounding box).
Milestone 2. If measurements show milestone 1 to be faster then proceed here. As withinDistance() needs to be called and returns true, expand the inner box creating a sort of inner convex hull polygon shape, starting with the 45-degree inner box from before. But don't track "too many" points. When withinDistance() returns false, an outer polygon frontier can be incrementally built similarly to the inside. To constrain the detail, for each quadrant of the circle, you might add no more than say 64 frontier points on each side. So that it's evenly distributed, you might furthermore limit points being added to a fixed 1/64th band per quadrant.
A problem with Milestone 2 is that it would make the shape mutable, to some extent. Some care would be needed to make it thread-safe or devise some other API approach.