#include <ModelAPI_ResultConstruction.h>
#include <GeomAPI_PlanarEdges.h>
+#include <Events_Error.h>
+
#include <BRep_Builder.hxx>
#include <Prs3d_Drawer.hxx>
#include <Prs3d.hxx>
const Standard_Integer theMode)
{
std::shared_ptr<GeomAPI_Shape> aShapePtr = ModelAPI_Tools::shape(myResult);
- if (!aShapePtr)
+ if (!aShapePtr) {
+ Events_Error::throwException("An empty AIS presentation: ModuleBase_ResultPrs");
return;
+ }
if (myIsSketchMode) {
myFacesList.clear();
ModuleBase_Tools::setDefaultDeviationCoefficient(myOriginalShape, Attributes());
AIS_Shape::Compute(thePresentationManager, thePresentation, theMode);
}
+ else
+ Events_Error::throwException("An empty AIS presentation: ModuleBase_ResultPrs");
}