// Created on: 1992-02-21 // Created by: Arnaud BOUZY // Copyright (c) 1992-1999 Matra Datavision // Copyright (c) 1999-2014 OPEN CASCADE SAS // // This file is part of Open CASCADE Technology software library. // // This library is free software; you can redistribute it and/or modify it under // the terms of the GNU Lesser General Public License version 2.1 as published // by the Free Software Foundation, with special exception defined in the file // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT // distribution for complete text of the license and disclaimer of any warranty. // // Alternatively, this file may be used under the terms of Open CASCADE // commercial license or contractual agreement. #ifndef _ExprIntrp_Analysis_HeaderFile #define _ExprIntrp_Analysis_HeaderFile #include "Standard.hxx" #include "Standard_DefineAlloc.hxx" #include "Standard_Handle.hxx" #include "Expr_GeneralExpression.hxx" #include "NCollection_List.hxx" #include "Expr_GeneralRelation.hxx" #include "Expr_GeneralFunction.hxx" #include "TCollection_AsciiString.hxx" #include "Standard_Integer.hxx" #include "Expr_NamedFunction.hxx" #include "NCollection_Sequence.hxx" #include "Expr_NamedExpression.hxx" class ExprIntrp_Generator; class Expr_GeneralExpression; class Expr_GeneralRelation; class TCollection_AsciiString; class Expr_GeneralFunction; class Expr_NamedFunction; class Expr_NamedExpression; class ExprIntrp_Analysis { public: DEFINE_STANDARD_ALLOC Standard_EXPORT ExprIntrp_Analysis(); Standard_EXPORT void SetMaster(const occ::handle& agen); Standard_EXPORT void Push(const occ::handle& exp); Standard_EXPORT void PushRelation(const occ::handle& rel); Standard_EXPORT void PushName(const TCollection_AsciiString& name); Standard_EXPORT void PushValue(const int degree); Standard_EXPORT void PushFunction(const occ::handle& func); Standard_EXPORT occ::handle Pop(); Standard_EXPORT occ::handle PopRelation(); Standard_EXPORT TCollection_AsciiString PopName(); Standard_EXPORT int PopValue(); Standard_EXPORT occ::handle PopFunction(); Standard_EXPORT bool IsExpStackEmpty() const; Standard_EXPORT bool IsRelStackEmpty() const; Standard_EXPORT void ResetAll(); Standard_EXPORT void Use(const occ::handle& func); Standard_EXPORT void Use(const occ::handle& named); Standard_EXPORT occ::handle GetNamed(const TCollection_AsciiString& name); Standard_EXPORT occ::handle GetFunction(const TCollection_AsciiString& name); private: NCollection_List> myGEStack; NCollection_List> myGRStack; NCollection_List> myGFStack; NCollection_List myNameStack; NCollection_List myValueStack; NCollection_Sequence> myFunctions; NCollection_Sequence> myNamed; occ::handle myMaster; }; #endif // _ExprIntrp_Analysis_HeaderFile