Drake
RewritingRule Class Reference

A RewritingRule, lhs => rhs, consists of two Patterns lhs and rhs. More...

#include <drake/common/symbolic_simplification.h>

Public Member Functions

 RewritingRule (Pattern lhs, Pattern rhs)
 Constructs a rewriting rule lhs => rhs. More...
 
 RewritingRule (const RewritingRule &)=default
 Default copy constructor. More...
 
 RewritingRule (RewritingRule &&)=default
 Default move constructor. More...
 
RewritingRuleoperator= (const RewritingRule &)=delete
 Deleted copy-assign operator. More...
 
RewritingRuleoperator= (RewritingRule &&)=delete
 Deleted move-assign operator. More...
 
 ~RewritingRule ()=default
 Default destructor. More...
 
const Patternlhs () const
 Returns the const reference of the LHS of the rewriting rule. More...
 
const Patternrhs () const
 Returns the const reference of the RHS of the rewriting rule. More...
 

Detailed Description

A RewritingRule, lhs => rhs, consists of two Patterns lhs and rhs.

A rewriting rule instructs a rewriter how to transform a given expression e. First, the rewriter tries to find a match between the expression e and the pattern lhs. If such a match is found, it applies the match result (substitution) to rhs. Otherwise, the same expression e is returned.

Constructor & Destructor Documentation

RewritingRule ( Pattern  lhs,
Pattern  rhs 
)
inline

Constructs a rewriting rule lhs => rhs.

Here is the call graph for this function:

RewritingRule ( const RewritingRule )
default

Default copy constructor.

RewritingRule ( RewritingRule &&  )
default

Default move constructor.

~RewritingRule ( )
default

Default destructor.

Here is the caller graph for this function:

Member Function Documentation

const Pattern& lhs ( ) const
inline

Returns the const reference of the LHS of the rewriting rule.

Here is the caller graph for this function:

RewritingRule& operator= ( const RewritingRule )
delete

Deleted copy-assign operator.

Here is the caller graph for this function:

RewritingRule& operator= ( RewritingRule &&  )
delete

Deleted move-assign operator.

const Pattern& rhs ( ) const
inline

Returns the const reference of the RHS of the rewriting rule.

Here is the caller graph for this function:


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