Seed7 - The extensible programming language
Seed7 FAQ Manual Screenshots Examples Libraries Algorithms Download Links
Libraries AES ARC4 Array ASN.1 Bigfile Bigint Bigrat Bin32 Bin64 Bitdata Bitmapfont Bitset Bitsetof Boolean Browser Bstring Bytedata Cards Category CC config Cgi Cgi dialog Char Charsets Cipher Clib_file Color CLI Commands Complex Console Crc32 Deflate DES Dialog Dir Draw Duration Echo Editline Enable_input Enable_io Enable_output Encoding Environment External_file File File system Float Font Forloop Ftp Getf Gethttp Gethttps Graph Graph_file Gzip Hash Hashsetof Hmac Html_ent Httpserv Idxarray Image Inflate Inflate file Inifile Integer Keybd Line Listener LZW Make Math Msgdigest Null_file Osfiles Picture utility Pixmap_file Pixmapfont PKCS #1 Poll Process Progs Propertyfile Rational Reference Ref_list Scanfile Scanstri Set Shell Smtp Sockbase Socket SQL base Stdio Strifile String Stritext Subrange Tar Text Time TLS/SSL Triple DES Unicode Utf16 Utf8 Vectorfont 3D Vector Wildcard Window Wrinum X.509 Xmldom Xml_ent Zip
Libraries
Progs Source Code
 previous   up   next 

Types
program
Type to describe a Seed7 program.

program

const type: program

Type to describe a Seed7 program.


Operator Summary
boolean
(in program: prog1) = (in program: prog2)
Check if two program values are equal.
boolean
(in program: prog1) <> (in program: prog2)
Check if two program values are not equal.

Function Summary
string
name (in program: aProgram)
Returns the name of aProgram without path and extension.
string
path (in program: aProgram)
Return the absolute path of the program aProgram.
program
parseFile (in string: fileName, in parseOptions: options, in array string: libraryDirs, in string: protFileName)
Parse the file with the name fileName.
program
parseStri (in string: stri, in parseOptions: options, in array string: libraryDirs, in string: protFileName)
Parse the given string.
reference
evaluate (in program: aProgram, in reference: anExpression)
Evaluate anExpression which is part of aProgram.
void
execute (in program: aProgram, in array string: parameters, in parseOptions: options, in string: protFileName)
Execute the program referred by aProgram.
reference
sysVar (in program: aProgram, in string: name)
Determine the value of the system variable name in aProgram.
integer
errorCount (in program: aProgram)
Determine the number of errors in aProgram.
ref_list
globalObjects (in program: aProgram)
Determine the list of global defined objects in aProgram.
reference
syobject (in program: aProgram, in string: name)
Determine object with name from program aProgram.
reference
match (in program: aProgram, in ref_list: expession)
Determine object from program aProgram which matches expession.
boolean
isVar (in reference: aReference)
Determine if a referenced object is variable.
void
setVar (in reference: aReference, in boolean: isVariable)
Set var flag of a referenced object.
category
category (in reference: aReference)
Get the category of a referenced object.
void
setCategory (in reference: aReference, in category: aCategory)
Set the category of aReference to aCategory.
ref_list
formalParams (in reference: funcRef)
Get the formal parameters of the function referenced by funcRef.
void
setFormalParams (in reference: funcRef, in ref_list: params)
Set the formal parameters of funcRef to params.
reference
resultVar (in reference: funcRef)
Gets the result variable of funcRef.
reference
resultInitValue (in reference: funcRef)
Gets the initialization value of the result variable of funcRef.
ref_list
localConsts (in reference: funcRef)
Gets the local constants of funcRef.
ref_list
localVars (in reference: funcRef)
Gets the local variables of funcRef.
reference
body (in reference: funcRef)
Gets the body of the function referenced by funcRef.
string
file (in reference: aReference)
Determine the file name of a referenced object.
integer
line (in reference: aReference)
Determine the line number of a referenced object.
integer
objNumber (in reference: aReference)
Delivers an unique number for each object

Operator Detail

=

const func boolean: (in program: prog1) = (in program: prog2)

Check if two program values are equal.

Returns:
TRUE if both values are equal, FALSE otherwise.

<>

const func boolean: (in program: prog1) <> (in program: prog2)

Check if two program values are not equal.

Returns:
FALSE if both values are equal, TRUE otherwise.

Function Detail

name

const func string: name (in program: aProgram)

Returns the name of aProgram without path and extension. This function does not follow symbolic links. It determines, with which name a program was called. When a symbolic link refers to a program, the name of the symbolic link is returned.

Returns:
the name of the program.

path

const func string: path (in program: aProgram)

Return the absolute path of the program aProgram. This function does follow symbolic links.

Returns:
the absolute path of the program.

parseFile

const func program: parseFile (in string: fileName, in parseOptions: options, in array string: libraryDirs, in string: protFileName)

Parse the file with the name fileName.

Returns:
the parsed program.
Raises:
RANGE_ERROR - fileName does not use the standard path representation or fileName is not representable in the system path type.
MEMORY_ERROR - An out of memory situation occurred.

parseStri

const func program: parseStri (in string: stri, in parseOptions: options, in array string: libraryDirs, in string: protFileName)

Parse the given string.

Returns:
the parsed program.
Raises:
MEMORY_ERROR - An out of memory situation occurred.

evaluate

const func reference: evaluate (in program: aProgram, in reference: anExpression)

Evaluate anExpression which is part of aProgram.

Returns:
the result of the evaluation.

execute

const proc: execute (in program: aProgram, in array string: parameters, in parseOptions: options, in string: protFileName)

Execute the program referred by aProgram.


sysVar

const func reference: sysVar (in program: aProgram, in string: name)

Determine the value of the system variable name in aProgram.

Returns:
a reference to the value of the system variable or NIL when no system variable name exists.

errorCount

const func integer: errorCount (in program: aProgram)

Determine the number of errors in aProgram.

Returns:
the number of errors.

globalObjects

const func ref_list: globalObjects (in program: aProgram)

Determine the list of global defined objects in aProgram. The returned list contains constant and variable objects in the same order as the definitions of the source program. Literal objects and local objects are not part of this list.

Returns:
the list of global defined objects.

syobject

const func reference: syobject (in program: aProgram, in string: name)

Determine object with name from program aProgram.

Returns:
a reference to the object or NIL when no object name exists.
Raises:
MEMORY_ERROR - When name cannot be converted to the internal representation.

match

const func reference: match (in program: aProgram, in ref_list: expession)

Determine object from program aProgram which matches expession.

Returns:
object from program.

isVar

const func boolean: isVar (in reference: aReference)

Determine if a referenced object is variable.

Returns:
TRUE if aReference is a variable, FALSE otherwise.
Raises:
RANGE_ERROR - When aReference is NIL.

setVar

const proc: setVar (in reference: aReference, in boolean: isVariable)

Set var flag of a referenced object.

Raises:
RANGE_ERROR - When aReference is NIL.

category

const func category: category (in reference: aReference)

Get the category of a referenced object.

Returns:
the category of the referenced object.
Raises:
RANGE_ERROR - When aReference is NIL.

setCategory

const proc: setCategory (in reference: aReference, in category: aCategory)

Set the category of aReference to aCategory.

Raises:
RANGE_ERROR - When aReference is NIL.

formalParams

const func ref_list: formalParams (in reference: funcRef)

Get the formal parameters of the function referenced by funcRef. For objects without parameters an empty list is returned.

Returns:
the formal parameters as ref_list.
Raises:
RANGE_ERROR - When funcRef is NIL.
MEMORY_ERROR - An out of memory situation occurred.

setFormalParams

const proc: setFormalParams (in reference: funcRef, in ref_list: params)

Set the formal parameters of funcRef to params.

Raises:
RANGE_ERROR - When funcRef is NIL.
MEMORY_ERROR - An out of memory situation occurred.

resultVar

const func reference: resultVar (in reference: funcRef)

Gets the result variable of funcRef.

Returns:
a reference to the result variable.
Raises:
RANGE_ERROR - When funcRef is NIL or category(funcRef) <> BLOCKOBJECT holds.

resultInitValue

const func reference: resultInitValue (in reference: funcRef)

Gets the initialization value of the result variable of funcRef.

Returns:
a reference to the initialization value.
Raises:
RANGE_ERROR - When funcRef is NIL or category(funcRef) <> BLOCKOBJECT holds.

localConsts

const func ref_list: localConsts (in reference: funcRef)

Gets the local constants of funcRef.

Returns:
the local constants as ref_list.
Raises:
RANGE_ERROR - When funcRef is NIL or category(funcRef) <> BLOCKOBJECT holds.
MEMORY_ERROR - An out of memory situation occurred.

localVars

const func ref_list: localVars (in reference: funcRef)

Gets the local variables of funcRef.

Returns:
the local variables as ref_list.
Raises:
RANGE_ERROR - When funcRef is NIL or category(funcRef) <> BLOCKOBJECT holds.
MEMORY_ERROR - An out of memory situation occurred.

body

const func reference: body (in reference: funcRef)

Gets the body of the function referenced by funcRef.

Returns:
the body expression of funcRef.
Raises:
RANGE_ERROR - When funcRef is NIL or category(funcRef) <> BLOCKOBJECT holds.

file

const func string: file (in reference: aReference)

Determine the file name of a referenced object.

Returns:
the file name of the referenced object.
Raises:
RANGE_ERROR - When aReference is NIL.
MEMORY_ERROR - Not enough memory to represent the result.

line

const func integer: line (in reference: aReference)

Determine the line number of a referenced object.

Returns:
the line number of the referenced object.
Raises:
RANGE_ERROR - When aReference is NIL.

objNumber

const func integer: objNumber (in reference: aReference)

Delivers an unique number for each object

Returns:
a unique object number.
Raises:
MEMORY_ERROR - Not enough memory to maintain the object table.


 previous   up   next