.class file, 22, 108
class keyword, 23, 105
CLASS retention policy, 273
Class(es), 105–124
abstract, 177–180, 181, 196
access levels of, 187
adapter, 659–660
and code, 21, 186
in collections, storing user-defined, 462–463
constructor.SeeConstructor(s)
controlling access to.SeeAccess control
definition of, 17
encapsulation achieved through, 122
final, 181
general form of, 105–106
generic.SeeGeneric class
inner, 145–148, 661–663
and interfaces, 192, 193, 194, 196
libraries, 21, 32
literal, 275
member.SeeMember, class
name and source file name, 22
nested, 145
packages as containers for, 183, 186
public, 187
scope, 43
ClassCastException, 218, 441, 442–443, 444,
445, 446, 464, 465, 466, 473, 478, 480, 483
ClassDefinition class, 435
ClassFileTransformer interface, 435
ClassLoader class, 418
ClassNotFoundException, 218, 595
CLASSPATH, 184, 185, 839
–classpath option, 185
clear( ), 441, 442, 465, 495, 505, 509, 816
Client/server model, 8, 10, 599
clone( ), 181, 412, 413–415, 432, 489, 495, 505,
508, 509, 514, 920
Cloneable interface, 413–415
CloneNotSupportedException, 218, 413
close( ), 294, 527, 549, 562, 563, 580, 594,
595, 596
Closeable interface, 561–562, 574, 578, 579, 586
COBOL, 4
CODE, 629, 630
Code base, 633
Code blocks, 26, 29–30, 42
static, 141–142
Code point, definition of, 401
Code unit, definition of, 401
CODEBASE, 629
codePointAt( ), 376, 383, 401
codePointBefore( ), 376, 383, 401
codePointCount( ), 376, 383
Collection interface, 440, 441
methods defined by, table of, 442
Collection-view, 439, 464–465
Collection(s), 315, 437–502
algorithms, 438, 475–480
into arrays, converting, 441, 442, 450–451
and autoboxing, 439–440, 451
classes, 448–458
Framework.SeeCollections Framework
interfaces, 438, 440–445
iterator, 438, 440, 458–462
and legacy classes and interfaces, 487
modifiable vs unmodifiable, 440
storing user-defined classes in, 462–463
and synchronization, 448, 479, 487
and type safety, 439, 475, 478
when to use, 502
Collections class, 438, 475–480
algorithms defined by, table of, 476–478
Collections Framework, 13, 92, 97, 267,
437–502
advantages of generics as applied to, 439,
484–487
changes to, 315, 439–440
overview, 438–439
Color class, 664, 682–684
constants 623–624
Combo boxes, Swing, 898–900
ComboBoxModel interface, 899
Comment, 22–23
documentation, 31, 991–996
Common Gateway interface (CGI), 10, 907–908
Comparable interface, 338, 433–434, 507, 559
Comparator interface, 440, 470, 472–473
comparator( ), 444, 456, 466
Comparators, 470, 472–475
compare( ), 387, 388, 473
compareAndSet( ), 789, 811
compareTo( ), 261, 262, 369–370, 387, 388, 391,
392, 393, 395, 400, 402, 432, 433–434, 508, 559
compareToIgnoreCase( ), 370
Compilation unit, 21
compile( ), 825–826
Compiler class, 422
Compiler, Java, 22
and main( ), 23–24
Index 1001