C G I L M P R S T U V

C

calculate(String, int, Vector) - Static method in class cw3e
This method implements the CALCULATE function.
checkName(String, Vector) - Static method in class TPLutils
This method checks to see whether the intended variable name is a reserved word or a integer.
createBoolean(String, int, Vector) - Static method in class cw3e
This method creates a new TPLboolean variable and instantiates it.
createInteger(String, int, Vector) - Static method in class cw3e
This method creates a new TPLinteger variable and instantiates it.
createString(String, int, Vector) - Static method in class cw3e
This method creates a new TPLstring variable and instantiates it.
cw3e - class cw3e.
Author: Joanne Louise Carter
Date: 06/01/05
Module: G6DICP Introduction to Computer Programming
Title: ICP Coursework 3
SCSiT Username: jxc04m

This program implements the entire TPL specification and extends it - the extended functions are documented in the readme.txt and include: BOOLEAN (TRUE/FALSE), CALCULATE on STRING, IF and END IF, and INPUT If an error is found then an appropriate error message is printed and the program ends - you must correct the error(s) to have the program run to completion.
cw3e() - Constructor for class cw3e
 

G

getInt(Vector, String, int, int) - Static method in class TPLutils
This method is to aid in CALCULATE and LET.
getString(Vector, String, int, int) - Static method in class TPLutils
This method is to aid in CALCULATE and LET.

I

ifStatement(String, int, Vector) - Static method in class cw3e
An IF statement.

L

let(String, int, Vector) - Static method in class cw3e
This method deals with assigning values to variables.

M

main(String[]) - Static method in class cw3e
The main method.

P

print(String, int, Vector) - Static method in class cw3e
This method takes the current line of code, processes it and then prints a result (a line of text, variable data etc) according to whether it is PRINT or PRINTLN.

R

readln() - Static method in class TPLutils
This method reads in input from the user and returns a String.

S

searchVector(Vector, String) - Static method in class TPLutils
This method searches through the tplData Vector to find a specific variable.
str2bool(String) - Static method in class TPLutils
This method converts a string to a boolean, or exits with an error message.
str2int(String) - Static method in class TPLutils
This method converts a string to an integer.

T

TPLboolean - class TPLboolean.
The TPL BOOLEAN variable.
TPLboolean(String, boolean) - Constructor for class TPLboolean
Sets up the variable.
TPLinteger - class TPLinteger.
The TPL INTEGER variable.
TPLinteger(String, int) - Constructor for class TPLinteger
Sets up the variable.
TPLstring - class TPLstring.
The TPL STRING variable.
TPLstring(String, String) - Constructor for class TPLstring
Sets up the variable.
TPLutils - class TPLutils.
 
TPLutils() - Constructor for class TPLutils
 
TPLvariable - class TPLvariable.
This is the basic TPL variable, it is used as template for the INTEGER and STRING TPL variables.
TPLvariable(String) - Constructor for class TPLvariable
Sets up the variable.

U

userInput(String, int, Vector) - Static method in class cw3e
This method asks the user for input for a variable value, then assigns the variable that value.

V

variableType(Vector, int) - Static method in class TPLutils
This method takes the variable from the Vector at the specified index and returns the data type (INTEGER or STRING) of the variable.

C G I L M P R S T U V