/* not with a <!> but with a wimper */
A - I
Abstraction - A simplified representation of something that is potentially quite complex. It is often not necessary to know the exact details of how something works, is represented or is implemented, because we can still make use of it in its simplified form. Object-oriented design often involves finding the right level of abstraction at which to work when modeling real-life objects. If the level is too high, then not enough detail will be captured. If the level is too low, then a program could be more complex and difficult to create and understand than it needs to be.
API - The Application Programming Interface. A set of definitions that you can make use of in writing programs. In the context of Java, these are the packages, classes, and interfaces that can be used to build complex applications without having to create everything from scratch.
Argument - Information passed to a method. Arguments are also sometimes called parameters. A method expecting to receive arguments must contain a formal argument declaration for each as part of its method header. When a method is called, the actual argument values are copied into the corresponding formal arguments.
Array - A fixed-size object that can hold zero or more items of the array's declared type.
Attribute - A particular usage of an instance variable. The set of attribute values held in a particular instance of a class define the current state of that instance. A class definition may impose particular constraints on the valid states of its instances by requiring that a particular attribute, or set of attributes, do not take on particular values. For instance, attributes holding coursework marks for a class should not hold negative values. Attributes should be manipulated by accessor and mutator methods.
Behavior - The methods of a class implement its behavior. A particular object's behavior is a combination of the method definitions of its class and the current state of the object.
Block Level Elements - are a type of structure created. to change text within the body of an HTML document. Block level elements can appear in the body of an HTML page. It can contain another block level as well as inline elements. By default, block-level elements begin on new lines. block level elements create larger structures (than inline elements).
Boolean - One of Java's primitive types. The boolean type has only two values: true and false.
Bounds - The limits of an array or collection. In Java, the lower limit is always zero. In the case of an array, the upper bound is one less than then length of the array, and is fixed. Indexing outside the bounds of an array or collection will result in an IndexOutOfBoundsException exception being thrown.
Build - Also known as "running". To take a peice of code and execute its functions.
CPU - The Central Processing Unit is the heart of a computer as it is the part that contains the computer's ability to obey instructions. Each type of CPU has its own instruction set.
Class - A programming language concept that allows data and methods to be grouped together. The class concept is fundamental to the notion of an object-oriented programming language. The methods of a class define the set of permitted operations on the class's data (its attributes). This close tie between data and operations means that an instance of a class - an object - is responsible for responding to messages received via its defining class's methods.
Class Constant - A variable defined as both final and static.
Class Inheritance - When a super class is extended by a sub class, a class inheritance relationship exists between them. The sub class inherits the methods and attributes of its super class. In Java, class inheritance is single inheritance. See interface inheritance for an alternative form of inheritance.
Class Method - A synonym for static method.
Comment - A piece of text intended for the human reader of a program. Compilers ignore their contents.
Compiler - A program which performs a process of compilation on a program written in a high level programming language.
Constant - A variable whose value may not be changed. In Java, these are implemented by final variables.
Constructor - Something automatically called when an instance of its class is created. A constructor always has the same name as its class, and has no return type. For instance
public class Ship {
public Ship(String name){
}
}
A class with no explicit constructor has an implicit no-arg constructor, which takes no arguments and has an empty body.
Data Type - There are eight primitive data types in Java; five of these represent numerical types of varying range and precision - double, float, int, long and short. The remaining three are used to representing single-bit values (boolean), single byte values (byte) and two-byte characters from the ISO Unicode character set (char).
Exception - An object representing the occurrence of an exceptional circumstance - typically, something that has gone wrong in the smooth running of a program. Exception objects are created from classes that extend the Throwable class. See checked exception and unchecked exception.
Expression - A combination of operands and operators that produces a resulting value. Expressions have a resulting type, that affects the context in which they may be used. See boolean expression and arithmetic expression, for instance.
For Loop - One of Java's three control structures used for looping. The other two are the while loop and do loop. A for loop consists of a loop header and a loop body. The header consists of three expressions separated by two semicolons and one or more of these may be omitted. The first expression is only evaluated once, at the point the loop is entered. The middle expression is a boolean expressionrepresenting the loop's termination test. An empty expression represents the value true. The third expression is evaluated after each completion of the loop's body. The loop terminates when the termination test gives the value false. The statements in the loop body might be executed zero or more times.
GUI - A Graphical User Interface is part of a program that allows user interaction via graphical components, such as menus, buttons, text areas, etc. Interaction often involves use of a mouse.
High Level Programming Language - Languages such as Java, C++, Ada, etc. which provide programmers with features such as control structures, methods, classes, packages, etc. These features are largely independent of any particularinstruction set, and hence programs written in these languages tend to be more portable than those written in low level programming languages.
HTTP - The HyperText Transfer Protocol is a set of rules defined to enable a Web client (browser) to interact with a Web server.
Identifier - A programmer-defined name for a variable, method, class or interface.
If-Else Statement - A control structure used to choose between performing one of two alternative actions.It is controlled by a boolean expression.
Immutable Object - An object whose state may not be changed. Objects of the String class are immutable, for instance - their length and contents are fixed once created.
Implicit Type Conversion - Type conversion that does not require a cast. Implicit type conversions typically do not involve any loss of information. For instance, combining an integer operand with a floating point operand in an arithmetic expression will result in an implicit type conversion of the integer to an equivalent floating point value.
Increment Operator - An operator (++) that adds one to its operand. It has two forms: pre-increment (++x) and post-increment (x++). In its pre-increment form, the result of the expression is the value of its argument after the increment. In its post-increment form, the result is the value of its argument before the increment is performed. After the following,
int a = 5, b = 5;
int y,z;
y = ++a;
z = b++
y has the value 6 and z has the value 5. Both a and b have the value 6.
Infinite Loop - A loop whose termination test never evaluates to false. Sometimes this is a deliberate act on the part of the programmer, using a construct such as
while(true) ...
or
for( ; ; ) ...
but it can sometimes be the result of a logical error in the programming of a normal loop condition or the statements in the body of the loop.
I - R
Infinite Recursion - Recursion that does not terminate. This can result from any of direct recursion, indirect recursion or mutual recursion. It is usually the result of a logical error, and can result in stack overflow.
Inheritance - A feature of object-oriented programming languages in which a sub type inherits methods and variables from its super type. Inheritance is most commonly used as a synonym for class inheritance{class!inheritance}, but interface inheritance is also a feature of some languages, including Java.
Inheritance Hierarchy - The relationship between super classes and sub classes is known as an inheritance hierarchy. Single inheritance of classes means that each class has only a single `parent' class and that the Object class is the ultimate ancestor of all classes - at the top of the hierarchy. Two classes that have the same immediate super class can be thought of as sibling sub classes. Multiple inheritance of interfaces gives the hierarchy a more complex structure than that resulting from simple class inheritance.
Initializer - A block defined at the outermost level of a class - similar to a method without a header. Initializer blocks are executed, in order, when an instance is created. They are executed before the constructor of the defining class, but after any super class constructor. They are one of the places in which blank final variables may be initialized.
Inner Class - A class defined inside an enclosing class or method. We use the term to refer to non-static nested classes.
Instance - A synonym for object. Objects of a class are instantiated when a class constructor is invoked via the new operator.
Instance Variable - A non-static field of a class. Each individual object of a class has its own copy of such a field. This is in contrast to a class variable which is shared by all instances of the class. Instance variables are used to model the attributes of a class.
IP Address - An Internet Protocol (IP) address for a networked computer. Currently, IP addresses consist of four byte values, written in dotted decimal notation, such as 129.12.0.1. In future, IP addresses will be sixteen bytes long to accommodate the expansion in the number of networked computers.
Iteration - Repetition of a set of statements, usually using a looping control structure, such as a while loop, for loop or do loop.
Java - A portable high level programming language released by Sun Microsystems.
Local Variable - A variable defined inside a method body.
Loop Variable - A variable used to control the operation of a loop, such as a for loop. Typically, a loop variable will be given an initial value and it is then incremented after each iteration until it reaches or passes a terminating value.
Low Level Programming Languages - Often known as `assembly languages', these provide little more than the basic instruction set of a particular Central Processing Unit. Hence programs written in low level programming languages tend to be less portable than those written in high level languages.
Memory Leak - A situation in which memory that is no longer being used has not been returned to the pool of free memory. A garbage collector is designed to return unreferenced objects to the free memory pool in order to avoid memory leaks.
Method - The part of a class definition that implements some of the behavior of objects of the class. The body of the method contains declarations of local variables and statements to implement the behavior. A method receives input via its arguments, if any, and may return a result if it has not been declared as void.
Method Overriding - A method defined in a super class may be overridden by a method of the same name defined in a sub class. The two methods must have the same name and number and types of formal arguments. Any checked exception thrown by the sub class version must match the type of one thrown by the super class version, or be a sub class of such an exception. However, the sub class version does not have to throw any exceptions that are thrown by the super class version. It is important to distinguish between method overriding and method overloading. Overloaded methods have the same names, but differ in their formal arguments. See overriding for breadth, overriding for chaining and overriding for restriction.
Method Result - The value returned from a method via a return statement. The type of the expression in the return statement must match the return type declared in the method header.
Modem - A modulator-demodulator. A hardware device used to connect a digital computer to an analogue telephone network by turning analogue signals into digital signals, and vice versa.
Module - A group of program components, typically with restricted visibility to program components in other modules. Java uses packages to implement this concept.
Monitor - An object with one or more synchronized methods.
Multiple Inheritance - The ability of a class or interface to extend more than one class or interface. In Java, multiple inheritance is only available in the following circumstances
Null - a In computing, a null pointer has a value reserved for indicating that the pointer does not refer to a valid object. Programs routinely use null pointers to represent conditions such as the end of a list of unknown length or the failure to perform some action; this use of null pointers can be compared to nullable types and to the Nothing value in an option type. Null pointers have different semantics than null values. A null pointer in most programming languages means "no value", while a null value in a relational database means "unknown value". This leads to important differences in practice: most programming languages will treat two null pointers as equal, but a relational database engine does not regard two null values as equal (since they represent unknown values, it is unknown whether they are equal).
Object - An instance of a particular class. In general, any number of objects may be constructed from a class definition (see singleton, however). The class to which an object belongs defines the general characteristics of all instances of that class. Within those characteristics, an object will behave according to the current state of its attributes and environment.
Object Construction - The creation of an object, usually via the new operator. When an object is created, an appropriate constructor from its class is invoked.
Object-Oreinted Language - Programming languages such as C++ and Java that allow the solution to a problem to be expressed in terms of objects which belong to classes.
Operand - An operand is an argument of an operator. Expressions involve combinations of operators and operands. The value of an expression is determined by applying the operation defined by each operator to the value of its operands.
Operator - A symbol, such as -, == or ?: taking one, two or three operands and yielding a result. Operators are used in both arithmetic expressions and boolean expressions.
Package - A named grouping of classes and interfaces that provides a package namespace. Classes, interfaces and class members without an explicit public, protected or private access modifier{access!modifier} have package visibility. Public classes and interfaces may be imported into other packages via an import statement.
Pixel - A picture element, typically a colored dot on a screen.
Primitive Type - Java's eight standard non-class types are primitive types: boolean, byte, char, double, float, int, long and short.
Protocol - A set of rules for interaction between two processes. A protocol is usually specified in a Uniform Resource Locator (URL) to indicate how a particular resource should be transferred from a Web server to the requesting client.
Punctuation - Symbols such as commas and semicolons, which a compiler uses to understand the structure of a program.
Recursion - Results from a method being invoked when an existing call to the same method has not yet returned. For instance
public static void countDown(int n){
if(n >= 0){
System.out.println(n);
countDown(n-1);
}
// else - base case. End of recursion.
}
See direct recursion, indirect recursion and mutual recursion for the different forms this can take.
Relative Filename - A filename whose full path is relative to some point within a file system tree - often the current working folder (directory). For instance
../bin/javac.exe
A relative filename could refer to different files at different times, depending upon the context in which it is being used. See absolute filename.
R - Z
Return Statement - A statement used to terminate the execution of a method. A method with void return type may only have return statements of the following form
return;
A method with any other return type must have at least one return statement of the form
return expression;
where the type of expression must match the return type of the method.
Return Type - The declared type of a method, appearing immediately before the method name, such as void in
public static void main(String[] args)
or Point[] in
public Point[] getPoints()
RGB Color Model - A color model based upon representing a color as three components: red, green and blue. See HSB Color Model.
Scope - A language's scope rules determine how widely variables, methods and classes are visible within a class or program. Local variables have a scope limited to the block in which they are defined, for instance. Private methods and variables have class scope, limiting their accessibility to their defining class. Java provides private, package, protected and public visibility.
Search Path - A list of folders (directories) to be searched - for a program or class, for instance.
Single Inheritance - In Java, a class may not extend more than one class. This means that Java has a single inheritance model for class inheritance. See multiple inheritance for the alternative.
Stack Overflow - Stack overflow occurs when too many items are pushed onto a stack with a finite capacity.
State - The current state of an object is represented by the combined values of its attributes. Protecting the state of an object from inappropriate inspection or modification is an important aspect of class design and we recommend the use of accessor methods and mutator methods to facilitate attribute protection and integrity. The design of a class is often an attempt to model the states of objects in the real-world. Unless there is a good match between the data types available in the language and the states to be modeled, class design may be complex. An important principle in class design is to ensure that an object is never put into an inconsistent state by responding to a message.
Statement - The basic building block of a Java method. There are many different types of statement in Java, for instance, the assignment statement, if statement, return statement and while loop.
Statement Terminator - The semicolon (;) is used to indicate the end of a statement.
Static Initializer - An initializer prefixed with the static reserved word. A static initializer is defined outside the methods of its enclosing class, and may only access the static fields and methods of its enclosing class.
Static Method - A static method (also known as a class method) is one with the static reserved word in its header. Static methods differ from all other methods in that they are not associated with any particular instance of the class to which they belong. They are usually accessed directly via the name of the class in which they are defined.
Static Nested Class - A nested class with the static reserved word in its header. Unlike inner classes, objects of static nested classes have no enclosing object. They are also known as nested top-level classes.
Static Type - The static type of an object is the declared type of the variable used to refer to it. See dynamic type.
Static Variable - A static variable defined inside a class body. Such a variable belongs to the class as a whole, and is, therefore, shared by all objects of the class. A class variable might be used to define the default value of an instance variable, for example, and would probably also be defined as final, too. They are also used to contain dynamic information that is shared between all instances of a class. For instance the next account number to be allocated in a bank account class. Care must be taken to ensure that access to shared information, such as this, is synchronized where multiple threads could be involved. Class variables are also used to give names to application-wide values or objects since they may be accessed directly via their containing class name rather than an instance of the class.
String - An instance of the String class. Strings consist of zero or more Unicode characters, and they are immutable, once created. A literal string is written between a pair of string delimiters ("), as in
"hello, world"
Sub Class - A class that extends its super class. A sub class inherits all of the members of its super class. All Java classes are sub classes of the Object class, which is at the root of the inheritance hierarchy. See sub type
Subordinate Inner Class - An inner class that performs well-defined subordinate tasks on behalf of its enclosing class.
Sub Type - A type with a parent super type. The sub-type/super-type relationship is more general than the sub-class/super-class relationship. A class that implements an interface is a sub type of the interface. An interface that extends another interface is also a sub type.
Super Class - A class that is extended by one or more sub classes. All Java classes have the Object class as a super class. See super type.
Super Type - A type with a child sub type. The sub-type/super-type relationship is more general than the sub-class/super-class relationship. An interface that is implemented by a class is a super type of the class. An interface that is extended by another interface is also a super type.
Switch Statement - A selection statement in which the value of an arithmetic expression {expression!arithmetic} is compared for a match against different case labels. If no match is found, the optional default label is selected For instance
switch(choice){
case 'q':
quit();
break;
case 'h':
help();
break;
default:
System.out.println("Unknown command: "+choice);
break;
}
Syntax Error - An error detected by the compiler during its parsing of a program. Syntax errors usually result from mis-ordering symbols within expressions and statements. Missing curly brackets and semicolons are common examples of syntax errors.
Toggle - To alternate between two values, such as true and false, on and off, or 1 and 0.
Top Level Class - A class defined either at the outermost level of a package or a static nested class.
Try Statement - The try statement acts as an exception handler - a place where exception objects are caught and dealt with. In its most general form, it consists of a try clause, one or more catch clauses and a finally clause.
try{
statement;
}
catch(Exception e){
statement;
}
finally{
statement;
}
Either of the catch clause and finally clause may be omitted, but not both.
Uninitialized Variable - A local variable that been declared, but has had no value assigned to it. The compiler will warn of variables which are used before being initialized.
Variable Declaration - The association of a variable with a particular type. It is important to make a distinction between the declaration of variables of primitive types and those of class types. A variable of primitive type acts as a container for a single value of its declared type. Declaration of a variable of a class type does not automatically cause an object of that type to be constructed and, by default, the variable will contain the value null. A variable of a class type acts as a holder for a reference to an object that is compatible with the variable's class type. Java's rules of polymorphism allow a variable of a class type to hold a reference to any object of its declared type or any of its sub types. A variable with a declared type of Object, therefore, may hold a reference to an object of any class, therefore.
While Loop - One of Java's three control structures used for looping. The other two are the do loop and for loop. A while loop consists of a boolean expression and a loop body. The condition is tested before the loop body is entered for the first time and re-tested each time the end of the body is completed. The loop terminates when the condition gives the value false. The statements in the loop body might be executed zero or more times.
White Space - Characters used to create visual spacing within a program. White spaces include space, tab, carriage return and line feed characters.
Zip File - A file used to store compressed versions of files. In connection with Java bytecode files, these have largely been superseded by Java Archive (JAR) files.