Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-07-12 08:20:43

0001 // Created on: 2018/03/21
0002 // Created by: Eugeny MALTCHIKOV
0003 // Copyright (c) 2018 OPEN CASCADE SAS
0004 //
0005 // This file is part of Open CASCADE Technology software library.
0006 //
0007 // This library is free software; you can redistribute it and/or modify it under
0008 // the terms of the GNU Lesser General Public License version 2.1 as published
0009 // by the Free Software Foundation, with special exception defined in the file
0010 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0011 // distribution for complete text of the license and disclaimer of any warranty.
0012 //
0013 // Alternatively, this file may be used under the terms of Open CASCADE
0014 // commercial license or contractual agreement.
0015 
0016 #ifndef _BRepTest_Objects_HeaderFile
0017 #define _BRepTest_Objects_HeaderFile
0018 
0019 #include <BRepTools_History.hxx>
0020 
0021 //! Provides the access to the useful tools common for the algorithms.
0022 class BRepTest_Objects
0023 {
0024 public:
0025   //! Sets the given history into the session.
0026   Standard_EXPORT static void SetHistory(const Handle(BRepTools_History)& theHistory);
0027 
0028   //! Adds the given history to the history in the session.
0029   Standard_EXPORT static void AddHistory(const Handle(BRepTools_History)& theHistory);
0030 
0031   //! Sets the history of the given algorithm into the session.
0032   template <class TheAlgo>
0033   static void SetHistory(const TopTools_ListOfShape& theArguments, TheAlgo& theAlgo)
0034   {
0035     SetHistory(new BRepTools_History(theArguments, theAlgo));
0036   }
0037 
0038   //! Adds the history of the given algorithm into the session.
0039   template <class TheAlgo>
0040   static void AddHistory(const TopTools_ListOfShape& theArguments, TheAlgo& theAlgo)
0041   {
0042     AddHistory(new BRepTools_History(theArguments, theAlgo));
0043   }
0044 
0045   //! Returns the history from the session.
0046   Standard_EXPORT static Handle(BRepTools_History) History();
0047 
0048   //! Enables/Disables the history saving
0049   Standard_EXPORT static void SetToFillHistory(const Standard_Boolean theFillHist);
0050 
0051   //! Returns the flag controlling the history collection
0052   Standard_EXPORT static Standard_Boolean IsHistoryNeeded();
0053 };
0054 
0055 #endif