>xabsl   The Extensible Agent Behavior Specification Language

XabslEngine Class Library Reference

 

xabsl::ConditionalEnumeratedExpression Class Reference

#include <XabslEnumeratedExpression.h>

Inheritance diagram for xabsl::ConditionalEnumeratedExpression:

Inheritance graph
[legend]
Collaboration diagram for xabsl::ConditionalEnumeratedExpression:

Collaboration graph
[legend]
List of all members.

Detailed Description

Represents an ANSI C (condition?expression:expression) question mark operator.

Author:
Martin Loetzsch

Max Risler

Definition at line 228 of file XabslEnumeratedExpression.h.


Public Member Functions

 ConditionalEnumeratedExpression (const Enumeration *enumeration, InputSource &input, ErrorHandler &errorHandler, Symbols &symbols, Option &option, State &state)
 Constructor.

 ~ConditionalEnumeratedExpression ()
 Destructor.

virtual int getValue () const
 Calculates the value of the decimal expression.


Private Attributes

const BooleanExpressioncondition
 The condition.

const EnumeratedExpressionexpression1
 The expression that is returned when the condition evaluates true.

const EnumeratedExpressionexpression2
 The expression that is returned when the condition evaluates false.


Constructor & Destructor Documentation

xabsl::ConditionalEnumeratedExpression::ConditionalEnumeratedExpression const Enumeration enumeration,
InputSource input,
ErrorHandler errorHandler,
Symbols symbols,
Option option,
State state
 

Constructor.

Creates the expression

Parameters:
input An input source for the intermediate code. It must be opened and read until A position where a expression starts.
errorHandler A reference to a ErrorHandler instance
symbols All available symbols
option The current option
state The current state

Definition at line 207 of file XabslEnumeratedExpression.cpp.

References xabsl::ErrorHandler::error(), xabsl::ErrorHandler::errorsOccurred, xabsl::ErrorHandler::message(), and XABSL_DEBUG_INIT.

Here is the call graph for this function:

xabsl::ConditionalEnumeratedExpression::~ConditionalEnumeratedExpression  ) 
 

Destructor.

Definition at line 244 of file XabslEnumeratedExpression.cpp.


Member Function Documentation

int xabsl::ConditionalEnumeratedExpression::getValue  )  const [virtual]
 

Calculates the value of the decimal expression.

Implements xabsl::EnumeratedExpression.

Definition at line 251 of file XabslEnumeratedExpression.cpp.

References xabsl::EnumeratedExpression::getValue(), and xabsl::BooleanExpression::getValue().

Here is the call graph for this function:


Member Data Documentation

const BooleanExpression* xabsl::ConditionalEnumeratedExpression::condition [private]
 

The condition.

Definition at line 255 of file XabslEnumeratedExpression.h.

const EnumeratedExpression* xabsl::ConditionalEnumeratedExpression::expression1 [private]
 

The expression that is returned when the condition evaluates true.

Definition at line 258 of file XabslEnumeratedExpression.h.

const EnumeratedExpression* xabsl::ConditionalEnumeratedExpression::expression2 [private]
 

The expression that is returned when the condition evaluates false.

Definition at line 261 of file XabslEnumeratedExpression.h.


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

Up | Main Page | Generated at Wed Aug 19 17:32:31 2009.