Breadcrumbs

parseIntegerExpression() Operation


Syntax


set anInteger = aString.parseIntegerExpression(aFormat, aLocale?)


Semantics

parseIntegerExpression() initializes an Integer object from a string using the given format expression. The format expression is a string with placeholders for number variables. The syntax is described in 

Number Formatting

.

Substitutables

aString

Can be any variable or object attribute having the type String.  

aFormat

Can be any variable or object attribute having the type String. The pattern syntax is described in 

Number Formatting

.

aLocale

Optional variable or object attribute having the type Basic Components::Basic Behavior::NumbersLocale.

This parameter can be used to define the following properties:

  • negativeSign: characters used to signify negative values. Usually '-'

  • positiveSign: characters used to signify positive values. Usually '+'

  • currencySymbol: e.g. '$'  

The other attributes of the NumbersLocale class are not relevant for Integers. 
Default values are given by the system locales.

Examples


set aString = anInteger.parseIntegerExpression("999MI"); 

Formatting examples can be found in 

Number Formatting

.



icon_download_example.png

<your example path>\E2E Action Language\BaseTypes\uml\formatExpressions.xml