Main Page | Namespace List | Class Hierarchy | Compound List | File List | Namespace Members | Compound Members | File Members

UTAP::RangeChecker Class Reference

A RangeChecker object is an oracle for predicting ranges of integer expressions and declared ranges of symbols. More...

#include <rangechecker.hh>

List of all members.

Public Member Functions

 RangeChecker (TimedAutomataSystem *)
 RangeChecker (TimedAutomataSystem *, const process_t &)
range_t getRange (expression_t) const
 Returns the range of an expression taking the current mapping into account.

range_t getDeclaredRange (expression_t expr) const
 Returns the declared range of a variable.

range_t getDeclaredRange (symbol_t symbol) const
 Returns the declared range of a variable.


Protected Member Functions

range_t getRange (symbol_t symbol) const
 Returns the range of a symbol taking the current mapping into account.

range_t rangeOfBinary (expression_t, uint32_t op, expression_t) const
 Returns the range of a binary expression.

bool evaluate (expression_t expr, int32_t &value) const


Detailed Description

A RangeChecker object is an oracle for predicting ranges of integer expressions and declared ranges of symbols.

For both situations the result might depend on the process context, e.g. a template parameter might be used in the expression or might have been used in the range declaration of an integer variable. So in these cases it is important to provide the process in which the expression should be evaluated.

For constant expressions, the actual value of the expression is returned. If the expression cannot be evaluated (it is not constant), then a range is computed based on the declared ranges of variables used in the expression (and on the values of any constants used).


Constructor & Destructor Documentation

RangeChecker::RangeChecker TimedAutomataSystem  ) 
 

RangeChecker::RangeChecker TimedAutomataSystem ,
const process_t
 


Member Function Documentation

bool UTAP::RangeChecker::evaluate expression_t  expr,
int32_t &  value
const [protected]
 

range_t RangeChecker::getDeclaredRange symbol_t  symbol  )  const
 

Returns the declared range of a variable.

The argument must be the symbol of a variable. The range returned is the declared range of that variable, which might depend on the current mapping.

range_t RangeChecker::getDeclaredRange expression_t  expr  )  const
 

Returns the declared range of a variable.

The argument must be an expression referring to a variable. The range returned is the declared range of that variable, which might depend on the current mapping.

range_t RangeChecker::getRange expression_t  expr  )  const
 

Returns the range of an expression taking the current mapping into account.

range_t RangeChecker::getRange symbol_t  symbol  )  const [protected]
 

Returns the range of a symbol taking the current mapping into account.

range_t RangeChecker::rangeOfBinary expression_t  left,
uint32_t  op,
expression_t  right
const [protected]
 

Returns the range of a binary expression.


The documentation for this class was generated from the following files:
Generated on Wed Jul 2 12:08:20 2003 for libutap by doxygen 1.3.2