Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:03:17

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 
0026   //! Sets the given history into the session.
0027   Standard_EXPORT static void SetHistory(const Handle(BRepTools_History)& theHistory);
0028 
0029   //! Adds the given history to the history in the session.
0030   Standard_EXPORT static void AddHistory(const Handle(BRepTools_History)& theHistory);
0031 
0032   //! Sets the history of the given algorithm into the session.
0033   template <class TheAlgo>
0034   static void SetHistory(const TopTools_ListOfShape& theArguments,
0035                          TheAlgo& theAlgo)
0036   {
0037     SetHistory(new BRepTools_History(theArguments, theAlgo));
0038   }
0039 
0040   //! Adds the history of the given algorithm into the session.
0041   template <class TheAlgo>
0042   static void AddHistory(const TopTools_ListOfShape& theArguments,
0043                          TheAlgo& theAlgo)
0044   {
0045     AddHistory(new BRepTools_History(theArguments, theAlgo));
0046   }
0047 
0048   //! Returns the history from the session.
0049   Standard_EXPORT static Handle(BRepTools_History) History();
0050 
0051   //! Enables/Disables the history saving
0052   Standard_EXPORT static void SetToFillHistory(const Standard_Boolean theFillHist);
0053 
0054   //! Returns the flag controlling the history collection
0055   Standard_EXPORT static Standard_Boolean IsHistoryNeeded();
0056 
0057 };
0058 
0059 #endif