rpt_expr_constant Class Reference

#include <constant.h>

Inheritance diagram for rpt_expr_constant:

rpt_expr

Public Member Functions

 ~rpt_expr_constant ()

Static Public Member Functions

static pointer create (const rpt_value::pointer &value)

Protected Member Functions

bool lvalue () const
const char * name () const
rpt_value::pointer evaluate () const

Private Member Functions

 rpt_expr_constant (const rpt_value::pointer &value)
 rpt_expr_constant ()
 rpt_expr_constant (const rpt_expr_constant &)
rpt_expr_constantoperator= (const rpt_expr_constant &)

Private Attributes

rpt_value::pointer value

Detailed Description

The rpt_expr_constant class is used to represent expression nodes which have a constant value.

Definition at line 29 of file constant.h.


Constructor & Destructor Documentation

rpt_expr_constant::~rpt_expr_constant (  ) 

The destructor.

rpt_expr_constant::rpt_expr_constant ( const rpt_value::pointer value  )  [private]

The constructor. It is private because all users of the API are required to create new instances via the create class method.

Parameters:
value The value of this constant expression.

rpt_expr_constant::rpt_expr_constant (  )  [private]

The default constructor. Do not use.

rpt_expr_constant::rpt_expr_constant ( const rpt_expr_constant  )  [private]

The copy constructor. Do not use.


Member Function Documentation

static pointer rpt_expr_constant::create ( const rpt_value::pointer value  )  [static]

The create class method is used to create new dynamically allocated instances.

Parameters:
value The value of this constant expression.

bool rpt_expr_constant::lvalue (  )  const [protected, virtual]

The lvalue method may be used to determine whether or not this expression node is an L-value (something which may appear on the left hand side of an assigment, a variable).

The default implementation, which is true for the vast majority of expression nodes, returns false.

Reimplemented from rpt_expr.

const char* rpt_expr_constant::name (  )  const [protected]

rpt_value::pointer rpt_expr_constant::evaluate (  )  const [protected, virtual]

The evaluate method may be used to calculate the value of the expression syntax tree.

Implements rpt_expr.

rpt_expr_constant& rpt_expr_constant::operator= ( const rpt_expr_constant  )  [private]

The assignment operator. Do not use.


Field Documentation

The value instance variable is used to remember

Definition at line 73 of file constant.h.


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

Generated on Wed Mar 12 23:37:42 2008 for Aegis by  doxygen 1.5.5