Rosetta  3.8
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Private Attributes | List of all members
numeric::expression_parser::SimpleExpressionCreator Class Reference

#include <Arithmetic.hh>

Inheritance diagram for numeric::expression_parser::SimpleExpressionCreator:
Inheritance graph
[legend]

Public Member Functions

 SimpleExpressionCreator ()
 
 SimpleExpressionCreator (std::list< std::string > const &varnames)
 
void add_variable (std::string const &varname)
 
ExpressionCOP handle_variable_expression (ArithmeticASTValue const &) override
 Factory method to be implemented by derived classes which may wish to handle variable expressions in a specific manner. More...
 
VariableExpressionOP get_variable (std::string const &varname)
 
std::map< std::string,
VariableExpressionOP
variables () const
 
- Public Member Functions inherited from numeric::expression_parser::ExpressionCreator
 ExpressionCreator ()
 
 ~ExpressionCreator () override
 
void visit (ArithmeticASTExpression const &) override
 
void visit (ArithmeticASTFunction const &) override
 
void visit (ArithmeticASTTerm const &) override
 
void visit (ArithmeticASTFactor const &) override
 
void visit (ArithmeticASTValue const &) override
 
void visit (ArithmeticASTRestTerm const &) override
 
void visit (ArithmeticASTRestExpression const &) override
 
void visit (ArithmeticASTNode const &) override
 
ExpressionCOP create_expression_tree (ArithmeticASTExpression const &)
 
virtual ExpressionCOP handle_function_expression (FunctionTokenCOP function, utility::vector1< ExpressionCOP > const &args)
 Factory method to be implemented by derived classes which may wish to handle function expressions in a specific manner. More...
 
- Public Member Functions inherited from numeric::expression_parser::ASTVisitor
 ~ASTVisitor () override
 Automatically generated virtual destructor for class deriving directly from ReferenceCount. More...
 
- Public Member Functions inherited from utility::pointer::ReferenceCount
 ReferenceCount ()
 Default constructor. More...
 
virtual ~ReferenceCount ()
 

Private Attributes

std::map< std::string,
VariableExpressionOP
variables_
 

Additional Inherited Members

- Public Types inherited from utility::pointer::ReferenceCount
typedef platform::Size Size
 
typedef platform::Size size_type
 

Constructor & Destructor Documentation

numeric::expression_parser::SimpleExpressionCreator::SimpleExpressionCreator ( )
numeric::expression_parser::SimpleExpressionCreator::SimpleExpressionCreator ( std::list< std::string > const &  varnames)

References add_variable().

Member Function Documentation

void numeric::expression_parser::SimpleExpressionCreator::add_variable ( std::string const &  varname)
VariableExpressionOP numeric::expression_parser::SimpleExpressionCreator::get_variable ( std::string const &  varname)
ExpressionCOP numeric::expression_parser::SimpleExpressionCreator::handle_variable_expression ( ArithmeticASTValue const &  )
overridevirtual

Factory method to be implemented by derived classes which may wish to handle variable expressions in a specific manner.

Factory method to be implemented by derived classes which may wish to handle variable expressions differently.

Reimplemented from numeric::expression_parser::ExpressionCreator.

References numeric::expression_parser::ArithmeticASTValue::is_literal(), numeric::expression_parser::ArithmeticASTValue::literal_value(), utility::to_string(), utility_exit_with_message, numeric::expression_parser::ArithmeticASTValue::variable_name(), and variables_.

std::map< std::string, VariableExpressionOP > numeric::expression_parser::SimpleExpressionCreator::variables ( ) const

References variables_.

Member Data Documentation

std::map< std::string, VariableExpressionOP > numeric::expression_parser::SimpleExpressionCreator::variables_
private

The documentation for this class was generated from the following files: