B.1 Syntax description

11.133GPPRelease 1999Test specification for Subscriber Interface Module (SIM) Application Programme Interface (API) for Java cardTS

Following is a syntax description in BNF.

<statement list> ::= [ <statement> \n] +

<statement> ::= <simple> | <switch> | <blank line>

<simple> ::= <reset> | <init> | <command> | <remark>

<reset> ::= RST

<init> ::= INI <hexdata>

<command> ::= CMD <hexdata> [ <response> ] ( <status> )

<response> ::= [ <hexdata> ]

<status> ::= ( <hexdata> )

<remark> ::= REM <text line>

<switch> ::= SWI { [<labelled list>] + }

<labelled list> ::= <label> : \n <statement list>

Description of syntax metalanguage:

\n represents a linebreak

[ x ] means x can appear optionally

[ x ] + means 1 or more appearances of x

x | y means x or y

[]{}: (bold) these are characters that appear literally in the script files

<text line> any character until the end of the line

<blank line> a line containing no text is acceptable

<hexdata> data written in hexadecimal, each byte separated from the following by a whitespace

Each simple statement beginning with 3 characters different than the ones defined indicates another tool command, and shall be ignored by the parser if not recognized.

‘ ‘, ‘\t’ : Can be used as separator

A long statement can be broken into several lines by using the character ‘\‘ at the end of each line which is not the last one in the statement.

For more details refer to the examples in clause B.3.