Changeset 2598 in Sophya for trunk/SophyaLib/SysTools/cexpre.h


Ignore:
Timestamp:
Aug 11, 2004, 3:10:25 PM (21 years ago)
Author:
ansari
Message:

Documentation (ajoutee ou completee) pour les classes du module SysTools - Reza 11 Aout 2004

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/SophyaLib/SysTools/cexpre.h

    r2512 r2598  
    1414namespace SOPHYA {
    1515
    16 //! Exception class used by  CExpressionEvaluator
     16/*!
     17  \ingroup SysTools
     18  \brief Exception class used by  CExpressionEvaluator
     19*/
    1720class CExprException : public PException {
    1821  public:
     
    2225
    2326//--------------------------------------------------------------------
    24 //! Base class for arithmetic expressions used by CExpressionEvaluator
     27/*!
     28  \ingroup SysTools
     29  \brief Base class for arithmetic expressions used by CExpressionEvaluator
     30  \sa CExpressionEvaluator
     31*/
    2532class CExprBase {
    2633public:
     
    3946};
    4047
     48/*!
     49  \ingroup SysTools
     50  \brief For formatted write (print) of expressions in a stream
     51*/
    4152inline ostream& operator << (ostream& s, CExprBase const & ex)
    4253  {  ex.Print(s);  return(s);  }
     
    4556class CE_FuncExp;
    4657//---------------------------------------------------------
    47 //! Class for evaluation of arithmetic expressions with C-like syntax
    4858class CExpressionEvaluator : public CExprBase {
    4959public:
    5060  CExpressionEvaluator(string const & sex);
    5161  virtual ~CExpressionEvaluator();
     62//! Evaluate the expression and returns the corresponding value.
    5263  virtual double Evaluate() const;
     64//! Alias for Evaluate()
    5365  inline double Value() const { return Evaluate(); }
     66//! Formatted output on a stream
    5467  virtual void  Print(ostream& os) const;
    5568
    5669protected:
     70//! Does the parsing and builds an CExprBase object.
    5771  CExprBase* ParseString(int extype, string fname, string const & sex,
    5872                    size_t off, size_t& stop, string& errmsg);
Note: See TracChangeset for help on using the changeset viewer.