mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-19 13:40:49 +03:00
0024952: Possibility to break Boolean operations algorithm by user request
class: BOPAlgo_Algo method: void BOPAlgo_Algo::SetProgressIndicator (const Handle(Message_ProgressIndicator)& theObj) Purpose: Set the Progress Indicator object <theObj>. method: void BOPAlgo_Algo::UserBreak() const Purpose: Breaks the execution if the break signal is indicated.
This commit is contained in:
@@ -19,6 +19,9 @@
|
||||
|
||||
#include <NCollection_BaseAllocator.hxx>
|
||||
|
||||
#include <Standard_ProgramError.hxx>
|
||||
#include <Standard_NotImplemented.hxx>
|
||||
|
||||
//=======================================================================
|
||||
// function:
|
||||
// purpose:
|
||||
@@ -106,6 +109,30 @@ Standard_Boolean BOPAlgo_Algo::RunParallel()const
|
||||
{
|
||||
return myRunParallel;
|
||||
}
|
||||
//=======================================================================
|
||||
//function : SetProgressIndicator
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
void BOPAlgo_Algo::SetProgressIndicator
|
||||
(const Handle(Message_ProgressIndicator)& theObj)
|
||||
{
|
||||
if (!theObj.IsNull()) {
|
||||
myProgressIndicator=theObj;
|
||||
}
|
||||
}
|
||||
//=======================================================================
|
||||
//function : UserBreak
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
void BOPAlgo_Algo::UserBreak() const
|
||||
{
|
||||
if (myProgressIndicator.IsNull()) {
|
||||
return;
|
||||
}
|
||||
if (myProgressIndicator->UserBreak()) {
|
||||
Standard_NotImplemented::Raise("");
|
||||
}
|
||||
}
|
||||
// myErrorStatus
|
||||
//
|
||||
// 1 - object is just initialized
|
||||
|
Reference in New Issue
Block a user