Java Reference
In-Depth Information
Appendix A. Full Code Examples
System Requirements
This appendix includes full, runnable code examples for each pattern. Most of the patterns in the main part of this
book included only the code that is crucial for your understanding of the pattern. This appendix includes all
required class files, and a RunPattern class, which shows you how the code runs, and includes print statements
specifying what occurs in the code.
The following patterns use Remote Method Invocation ( RMI ) in their code examples: Callback, HOPP, Router,
Session, Successive Update, Transaction, and Worker Thread.
To run these examples, your computer must be network-enabled. Specifically, your system must be able to use
TCP/IP sockets for networking and recognize " localhost " as a valid loopback IP address.
The rmiregistry is started from the RunPattern file in each of these examples. Because rmiregistry is a server
process, these examples will appear to block when they are finished. You must manually terminate the Java
process to exit the rmiregistry.
 
 
Search WWH ::




Custom Search