UIEvolutin Inc.
UJML Language Reference
boolean

A boolean is a logical value that is always either true or false.

Boolean data types are logical values. They may be used in logical operations, to represent 'switches' or anywhere you need a value that is either 'on' or 'off.' Boolean values may be the result of boolean expressions using logical operators. See Expressions, Operators.

Booleans in UJML

In UJML, a boolean is a primitive data type that is stored by value. It supports only two possible values, true or false.

Boolean literals

The values true and false are also the only two possible literal values. See Literals and Constants.

The following example shows how to declare a boolean variable. It is part of the assignment.ujml sample.

<var name="mBooleanVar" type="boolean"/>

 

The following example shows how to set the variable declared above to a boolean literal. It is part of the assignment.ujml sample.

mBooleanVar = true;

 

The following example shows how to set the variable declared above to the result of a boolean expression. It is part of the assignment.ujml sample.

mIntVar = 100;
mBooleanVar = (mIntVar &_GT; 99);
Copyright (c) 2000-2007 UIEvolution, Inc. All rights reserved.
What do you think about this topic? Send feedback!