The class library is still evolving - We hav got as far as 1.0.2. Your class library may be different - see your own local documentation. For example on the Sun Workstations at csci.csusb.edu (only) see //localhost/usr/local/hotjava/doc/api/packages.html for the real skinny.
The class library from an API.
The following pointers are to descriptions of the
current release of the Java classes.
JavaSoft API Documentation
The classes are grouped into packages - this means that they can share certain
mtheods and field not available thru the API.
Language Foundation Classes
Package java.lang contains essential Java classes, including numerics,
strings, objects, compiler, runtime, security and threads. Unlike other
packages, java.lang is automatically imported into every Java program.
[ Package-java.lang.html ]
Input/Output package java.io
Package java.io provides a set of input and output streams to read and
write data to files, strings, and other sources.
[ Package-java.java.io.html ]
Utility Class Library
Package java.util contains miscellaneous utility classes, including generic
data structures, settable bits class, time, date, string manipulation,
random number generation, system properties, notification, and enumeration
of data structures.
[ Package-java.util.html ]
Abstract Window Toolkit Library
Package java.awt provides user interface features such as windows, dialog
boxes, buttons, checkboxes, lists, menus, scrollbars and text fields.
It is said to be Abstract because it is device and operating system
independent - much to the irritation of some programmers who take their
revenge by inventing other meanings for the acronym.
[ AWT ]
below and
[ Package-java.awt.html ]
Applets
Package java.applet enables construction of applets. It also provides
information about an applet's parent document, about other applets in that
document, and enables an applet to play audio.
See
[ Applet ]
below and
[ Package-java.applet.html ]
Network Interface Class Library
Package java.net network support, including URLs, TCP sockets, UDP sockets,
IP addresses and a binary-to-text converter.
[ Package-java.net.html ]
Images - Audio and Visual
Package java.image is for managing image data, such as the setting the
color model, cropping, color filtering, setting pixel values and grabbing
snapshots.
Road_works_ahead
Two question marks ??
[ 1_below ]
indicate that I haven't found the data yet.
If you have found the answer in any offical documentation please
send it to dick@csci.csusb.edu where it will be incorporated with
an acknowledgement.
These are working notes and are being revised daily. Again I am
open to corrections and improvements.
Data Types
[ java.semantics.html ]
This provides a system-independent model of the operating system. It includes the standard input and output streams for example. The standard input streams are used for reading character data. The standard output streams are used for printing. For example:
System.out.println("Hello World!");
The System Class represents a single and predefined real object.
So it cannot have objects of type System(instances)
Nor can it be subclassed.
System Variables
public static void arraycopy(Object from_source, int from_source_position,
Object to_destination, int to_destination_position,
int length)Precondition: Both arrays exist and have space for at least length objects.
Postcondition: First length Objects in the second array equal those in first array.
Invariant: The first array.
. . . . . . . . . ( end of section System Methods) <<Contents | Index>>
Vectors [ java.util.Vector.html ] expand when needed.
For all C:Classes, A:Classes=array_of_C, i:identifier, e:expression, a:array_of_C, v:array_of_C_variable, ec:C expression, C []::Classes=class of arrays of objects of class C::=A, C [] i::declaration=declare_an_array_of_C, C i []::declaration=declare_an_array_of_C, v=a::expression(A)=afterwards v refers to array a, v[e]=ec::expression(C)=afterwards the e.th element of v has value ec but no other elements of v have been effected, new C [ e ]::expression(A)=a new array of e C's, a.length::int=number of items of class C in array a, a[e]::expression(C)=the e.th element of array a, (C[])ec::expression(A)=an array with element ec of length 1?? [ 1_below ]
For all A:Classes, B:subclasses(A), B[] in subclasses(A[]).
For arrays of characters see character strings [ String and StringBuffer ]
For arrays indexed by general objects see hash tables [ HashTable ]
Warning: the behavior specified for mathematical functions is implementation dependent. For example they are supposed to throw an exception when the answer is not a number (eg sqrt(-1)). However they have been implemented as calling the standard C library functions and so return Double.NaN(Double's IEEE Not-a-Number value).
AWT Container
. . . . . . . . . ( end of section AWT) <<Contents | Index>>
Applet
. . . . . . . . . ( end of section Object) <<Contents | Index>>
. . . . . . . . . ( end of section Object Hierarchy) <<Contents | Index>>
. . . . . . . . . ( end of section The Predefined Classes in Java) <<Contents | Index>>
End Notes
. . . . . . . . . ( end of section End Notes) <<Contents | Index>>