ns3::rapidnet::RangeExpr Class Reference
[RapidNet Library]

Range expression. It is one of the 4 types as defined by Interval. More...

#include <expression.h>

Inheritance diagram for ns3::rapidnet::RangeExpr:

Inheritance graph
[legend]
Collaboration diagram for ns3::rapidnet::RangeExpr:

Collaboration graph
[legend]

List of all members.

Public Types

enum  Interval { RANGEOO, RANGEOC, RANGECO, RANGECC }
 The type of the RangeExpr. More...

Public Member Functions

virtual Ptr< ValueEval (Ptr< Tuple > tuple)
 Evaluates the expression against the given tuple. Note that all expressions are evaluated only against a tuple. The expression may use attributes of the tuple by using a VarExpr object. Or it may not use any attributes at all.
virtual string ToString () const
 String representation of the expression.

Static Public Member Functions

static Ptr< ExpressionNew (Interval type, Ptr< Expression > value, Ptr< Expression > start, Ptr< Expression > end)
 Factory method to create a new range expression.


Detailed Description

Range expression. It is one of the 4 types as defined by Interval.

It uses operators LT, LTE, GT and GTE on the arguments for evaluation.

See also:
Interval.

Member Enumeration Documentation

The type of the RangeExpr.

Enumerator:
RANGEOO  Open on both sides: ().
RANGEOC  Open on the left, closed on the right: (].
RANGECO  Closed on the left, open on the right: [).
RANGECC  Closed on both sides: [].


Member Function Documentation

virtual Ptr<Value> ns3::rapidnet::RangeExpr::Eval ( Ptr< Tuple tuple  )  [virtual]

Evaluates the expression against the given tuple. Note that all expressions are evaluated only against a tuple. The expression may use attributes of the tuple by using a VarExpr object. Or it may not use any attributes at all.

See also:
VarExpr

Implements ns3::rapidnet::Expression.

static Ptr<Expression> ns3::rapidnet::RangeExpr::New ( Interval  type,
Ptr< Expression value,
Ptr< Expression start,
Ptr< Expression end 
) [static]

Factory method to create a new range expression.

Parameters:
type The type of range expression.
value The value to be tested for being in range.
start The lower limit of the range.
end The upper limit of the range.


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

Generated on Fri Apr 9 15:01:11 2010 for NS-3 by  doxygen 1.5.8