O'Reilly logo

THE Java™ Programming Language, Fourth Edition by James Gosling, Ken Arnold, David Holmes

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 18. Packages

 

For some reason a glaze passes over people's faces when you say “Canada”. Maybe we should invade South Dakota or something.

 
 --Sandra Gotlieb, wife of Canadian ambassador to U.S. (1981–1989)

Packages define units of software that can be distributed independently and combined with other packages to form applications. Packages have members that are related classes, interfaces, and subpackages, and may contain additional resource files (such as images) used by the classes in the package. Packages are useful for several reasons:

  • Packages create groupings for related interfaces and classes. For example, a set of library classes for performing statistical analysis could be grouped together in a stats package. The package can be placed ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required