add abstract method AbstractBoundingBox.overlap()
@@ -8,7 +8,7 @@ from ezdxf.math import Vec3, Vec2
if TYPE_CHECKING:
from ezdxf.math import Vertex, AnyVec
-__all__ = ["BoundingBox2d", "BoundingBox"]
+__all__ = ["BoundingBox2d", "BoundingBox", "AbstractBoundingBox"]
class AbstractBoundingBox:
@@ -53,6 +53,10 @@ class AbstractBoundingBox:
def intersect(self, other: "AbstractBoundingBox") -> bool:
pass
+ @abc.abstractmethod
+ def overlap(self, other: "AbstractBoundingBox") -> bool:
+ pass
+
def any_inside(self, vertices: Iterable["Vertex"]) -> bool:
"""Returns ``True`` if any vertex is inside this bounding box.
