[Skip Navigation] [CSUSB] / [CNS] / [Comp Sci Dept] / [R J Botting] / [Samples] / java.glossary
[Index] [Contents] [Source Text] [About] [Notation] [Copyright] [Comment/Contact] [Search ]
Tue Sep 18 15:25:52 PDT 2007


    A Glossary for the Java Language

      More on Java

      [ java.html ] [ java.syntax.html ] [ java.semantics.html ] [ java.packages.html ] [ java..class.tree..html ]

      See Also

      Roedy Green's Java Glossary for Novices: [ gloss.htm ]


      These are working notes and are being revised daily. I am open to corrections and improvements. [ ../mailme.html ] Two question marks ?? indicate that I haven't found the data yet. If you have found the answer in any official documentation please use the [Contact] button to tell me and your contribution will be incorporated with an acknowledgment.


    1. Overloading::=One name for several different types of object or function.
    2. Interfaces::=describes what you can do with the set of classes that implements the interfases. An interface is a list of functions that the classes must provide.
    3. Package::=unrelated collection of classes and interfaces. A file that starts with a package specifier P generates classes C in directory P with a file C.class that can be imported as P.* or P.C.


    4. default_modifier::=In the absence of any modifiers fields are associated with objects and are visible to all classes in a package, and accessible by a subclass in the same package only.

    5. public::modifier=A public variable or function can be accessed in any other class.

    6. private::=modifierA private variable or function can only be accessed its own class.

    7. protected::modifier=A degree of hiding lie between public and private, subclasses and classes in the same package have access to these items. -- unwise since any class can claim to be a member of the same package! Note for C++ programming, the C++ protected is the Java 1.0 private_protected. (Thanks to Andrew who correct this July 2007)

    8. private_protected::=`A private protected field or function can be accessed by any subclass, but can not be used otherwise', -- in Java 1.0 only, and equivalent to the C++ protected. This is deprecated by 1.5.

    9. static::=A variable or functions associated with a class rather than with the objects of the class.

      Note for C programmers. In C a static variable declared in a functions is the same variable each time you call it. This is not available in Java. In C a static variable declared outside a function is shared by the set of functions in the same file and following the declaration an hidden from other functions. In Java a static variable is shared by all functions in that class. Whether other classes can access it depend on whether it is private, public, and/or protected. A Java variable that is nonstatic is something that is not found in C. Each object in the class has its own variable, and all functions refer to that particular variable. The variable is created as part of the object and deleted with it.

      In Java instance variables are the same each time you call them. A variable or function is declared to be static when it associated with the class of objects rather than a particular object in that class. This means that a static function can not refer any data in an object - because it has no object. It also means that static data is essentially shared in common by every object but only stored in a single place. If you are in doubt about whether some data should be static or not - ask yourself how many times it occurs: once per class(static) or once per object(not static) or many time per object (its in a different class!).

    10. final::=once initialized it can not be changed. A variable(a field of a class or object) is declared final when you want it to keep its initial value for ever. It makes it a constant variable. A class is declared as final if it can not be extended.

    11. native::=Preprogrammed in another language and running as machine code. For a tutorial on a way to integrate C functions into Java methods see [ index.html ]

    12. synchronized::=Only one thread can execute this at a time. A method or block of code is marked as synchronized if only one thread of control can be in it at a time. Other threads are locked out. The code is reentrant. It protects resources from interference by multiple access at one time.

    13. abstract::method=A method that must exist for objects in a class but is fully defined only in subclasses,
    14. abstract::class=A class with one or more abstract methods.
    15. abstract::=not concrete, not yet implemented, deferred, prototypical. An abstract method is one that is defined in classes derived from this class. All subclasses have a version as defined in the base class or also declare it as abstract. Certain methods can not be abstract: constructors, static, private, final, native, synchronized, plus those that override superclass methods. An abstract method makes the whole class abstract. A class that inherits an abstract method and does not override it is also an abstract class. An abstract class can not be used to construct new objects. You can only call an abstract method via an object in a class that has extended the abstract class and defined all the abstract methods.

    16. threadsafe::= If another thread excuting this code at the same time can not change the value of a variable then the variable is threadsafe and the compiler may do clever things with it to make the code faster or smaller..

    17. transient::=something that does last longer than a function call. If an object can exist longer than a given applet....is persistent.... then its transient data does not have to be preserved when a function exits.


    18. applet::=A small program that can be sent across a network and interpreted safely on the receiving machine.
    19. AWT::=awt.
    20. awt::=Abstract windowing toolkit, another windowing toolkit. A set of machine independent classes that make it easier to create graphic user interfaces and output.
    21. bytecode::= [ byte_code] .
    22. byte_code::=a way of describing classes as a stream of byte oriented machine code for the Java Virtual Machine.
    23. file::=A collection of data. A Java source code file defines one or more classes, interfaces to be added to a package. [ class ] [ interface ] [ Package ]
    24. class::=Defines a collection of knowledge and know how. Classes are defined as declaring variables(fields) and functions(methods) associated with the objects of that class, and also with the class itself.. [ function ] [ method ] [ object ] [ variable ]

    25. field::=A component or member of a class that holds data about and object or about the class, a variable.
    26. function::computing=A named piece of code that returns a value and may also do something
    27. function::java=A piece of know-how attached to a class or accessed via an object
    28. implements::=a class can claim to implement an interface if it provides definitions for all the functions listed in the interface. A class can implement many interfaces and also extend one other class.

    29. interface::=Describes a set of classes in terms of what they can do for you, but allows each class to implement these methods in any way that you wish.

    30. JDK::=Java Development Kit: the compiler: javac, interpreter: java, and the classes. [ javac ] [ java ] , Later called an SDK.

    31. method::=A piece of "know-how". A procedure or function that is associated with an object or to a class.

    32. object::=An instance of a class. [ class ]
    33. procedure::ComputerScience=`A named piece of code that does something for a caller'.
    34. procedure::java=a void function. [ function ]
    35. static::=something associated with a class rather than an object. [ class ] [ object ]

    36. variable::Java=A piece of data(knowledge) associated with a class or an object.

    37. virtual_machine::=A hypothetical machine that can be emulated on many different actual machines.
    38. void::=word used in place of a type to indicate that a function does not return a value. -- introduced in ANSI C and still confusing people 10 years later.

    39. womb::=Java applets are kept alive inside a running program on the hosts machine - this called the womb. It also stops the applet from doing things that might be insecure.


    40. null::Object=nonexistent object.

    . . . . . . . . . ( end of section A Glossary for the Java Language) <<Contents | End>>