Java Reference
In-Depth Information
Solution
Download the latest archive of the topic source files, unpack it, and run Maven (see Auto-
mating Dependencies, Compilation, Testing, and Deployment with Apache Maven ) to com-
pile the files.
Discussion
The source code used as examples in this topic is drawn from several source code repositor-
ies that have been in continuous development since 1995. These are listed in Table 1-1 .
Table 1-1. The main source repositories
Repository name Github.com URL
Package description
Approx. size
javasrc
http://github.com/IanDarwin/javasrc
Java classes from all APIs 1,200 classes
darwinsys-api
http://github.com/Iandarwin/darwinsys-api A published API
250 classes
A small number of examples are drawn from the older javasrcee (Java EE) examples, which
I split off from javasrc due to the overall size; this is also on GitHub .
You can download these repositories from the GitHub URLs shown in Table 1-1 . GitHub al-
lows you to download, by use of git clone , a ZIP file of the entire repository's current
state, or to view individual files on the web interface. Downloading with git clone instead
of as an archive is preferred because you can then update at any time with a simple git pull
command. And with the amount of updating this has undergone for Java 8, you are sure to
find changes after the topic is published.
If you are not familiar with Git, see CVS, Subversion, Git, Oh My! .
javasrc
This is the largest repo, and consists primarily of code written to show a particular feature or
API. The files are organized into subdirectories by topic, many of which correspond more or
less to book chapters—for example, a directory for strings examples ( Chapter 3 ), regex for
regular expressions ( Chapter 4 ) , numbers ( Chapter 5 ), and so on. The archive also contains
the index by name and index by chapter files from the download site, so you can easily find
the files you need.
Search WWH ::




Custom Search