Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-06-04 08:42:57

0001 // Created on: 1992-02-21
0002 // Created by: Arnaud BOUZY
0003 // Copyright (c) 1992-1999 Matra Datavision
0004 // Copyright (c) 1999-2014 OPEN CASCADE SAS
0005 //
0006 // This file is part of Open CASCADE Technology software library.
0007 //
0008 // This library is free software; you can redistribute it and/or modify it under
0009 // the terms of the GNU Lesser General Public License version 2.1 as published
0010 // by the Free Software Foundation, with special exception defined in the file
0011 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0012 // distribution for complete text of the license and disclaimer of any warranty.
0013 //
0014 // Alternatively, this file may be used under the terms of Open CASCADE
0015 // commercial license or contractual agreement.
0016 
0017 #ifndef _ExprIntrp_Analysis_HeaderFile
0018 #define _ExprIntrp_Analysis_HeaderFile
0019 
0020 #include <Standard.hxx>
0021 #include <Standard_DefineAlloc.hxx>
0022 #include <Standard_Handle.hxx>
0023 
0024 #include <ExprIntrp_StackOfGeneralExpression.hxx>
0025 #include <ExprIntrp_StackOfGeneralRelation.hxx>
0026 #include <ExprIntrp_StackOfGeneralFunction.hxx>
0027 #include <TColStd_ListOfAsciiString.hxx>
0028 #include <TColStd_ListOfInteger.hxx>
0029 #include <ExprIntrp_SequenceOfNamedFunction.hxx>
0030 #include <ExprIntrp_SequenceOfNamedExpression.hxx>
0031 #include <Standard_Integer.hxx>
0032 class ExprIntrp_Generator;
0033 class Expr_GeneralExpression;
0034 class Expr_GeneralRelation;
0035 class TCollection_AsciiString;
0036 class Expr_GeneralFunction;
0037 class Expr_NamedFunction;
0038 class Expr_NamedExpression;
0039 
0040 class ExprIntrp_Analysis
0041 {
0042 public:
0043   DEFINE_STANDARD_ALLOC
0044 
0045   Standard_EXPORT ExprIntrp_Analysis();
0046 
0047   Standard_EXPORT void SetMaster(const Handle(ExprIntrp_Generator)& agen);
0048 
0049   Standard_EXPORT void Push(const Handle(Expr_GeneralExpression)& exp);
0050 
0051   Standard_EXPORT void PushRelation(const Handle(Expr_GeneralRelation)& rel);
0052 
0053   Standard_EXPORT void PushName(const TCollection_AsciiString& name);
0054 
0055   Standard_EXPORT void PushValue(const Standard_Integer degree);
0056 
0057   Standard_EXPORT void PushFunction(const Handle(Expr_GeneralFunction)& func);
0058 
0059   Standard_EXPORT Handle(Expr_GeneralExpression) Pop();
0060 
0061   Standard_EXPORT Handle(Expr_GeneralRelation) PopRelation();
0062 
0063   Standard_EXPORT TCollection_AsciiString PopName();
0064 
0065   Standard_EXPORT Standard_Integer PopValue();
0066 
0067   Standard_EXPORT Handle(Expr_GeneralFunction) PopFunction();
0068 
0069   Standard_EXPORT Standard_Boolean IsExpStackEmpty() const;
0070 
0071   Standard_EXPORT Standard_Boolean IsRelStackEmpty() const;
0072 
0073   Standard_EXPORT void ResetAll();
0074 
0075   Standard_EXPORT void Use(const Handle(Expr_NamedFunction)& func);
0076 
0077   Standard_EXPORT void Use(const Handle(Expr_NamedExpression)& named);
0078 
0079   Standard_EXPORT Handle(Expr_NamedExpression) GetNamed(const TCollection_AsciiString& name);
0080 
0081   Standard_EXPORT Handle(Expr_NamedFunction) GetFunction(const TCollection_AsciiString& name);
0082 
0083 protected:
0084 private:
0085   ExprIntrp_StackOfGeneralExpression  myGEStack;
0086   ExprIntrp_StackOfGeneralRelation    myGRStack;
0087   ExprIntrp_StackOfGeneralFunction    myGFStack;
0088   TColStd_ListOfAsciiString           myNameStack;
0089   TColStd_ListOfInteger               myValueStack;
0090   ExprIntrp_SequenceOfNamedFunction   myFunctions;
0091   ExprIntrp_SequenceOfNamedExpression myNamed;
0092   Handle(ExprIntrp_Generator)         myMaster;
0093 };
0094 
0095 #endif // _ExprIntrp_Analysis_HeaderFile