class ClearWorkSpaceDocumentUseCase(object):
    """Clear of the workspace

    Args:
        object : active CAD-model
    """

    def call(self, detailSquares):
        import FreeCAD as App

        for key in detailSquares:
            for renderPrimitive in detailSquares[key]:
                primitivePart = App.ActiveDocument.getObjectsByLabel(
                    renderPrimitive.cadLabel
                )[0]
                App.ActiveDocument.removeObject(primitivePart.Name)
