Computing Reviews
Today's Issue Hot Topics Search Browse Recommended My Account Log In
Review Help
Search
TCP/IP sockets in Java : practical guide for programmers
Calvert K., Donahoo M., Morgan Kaufmann Publishers Inc., San Francisco, CA, 2002. 116 pp. Type: Book (9781558606852)
Date Reviewed: Mar 18 2003

This is an excellent primer on the Java implementation of TCP/IP sockets. The small, thin size of the book is deceptive; the text is laden with interesting details that build on one another using carefully designed programming examples.

The authors have the difficult task of introducing a new subject, the programming of network sockets, to experienced Java users. Their assumptions about what the readers know or do not know are very judicious. The authors include a full page detailing what this book “is not,” which is forbidding, but direct. They assume that their users are experienced in object-oriented programming in Java. Indeed, their examples rightfully make use of relatively advanced object-oriented programming concepts without too much explanation.

The authors also assume that readers have absolutely no knowledge of transmission control protocol/Internet protocol (TCP/IP), socket classes, or network programming. Chapters 1 and 2 therefore introduce networking terms and concepts, and provide simple programs for Java socket classes. At the end of chapter 2, however, when the authors recap the differences between TCP and user datagram protocol (UDP), they use general statements such as “...by the time a call to send() returns...” or “...if receive() is called ...” without indicating which host, the client or the server, is doing the calling. Programmers new to TCP/IP and UDP will find this vagueness confusing as they follow the chain of back-and-forth events.

Chapter 3 focuses on information framing and parsing formats, encoding and decoding schemes, and stream composition methods. Programmers not familiar with networking protocols will find that this chapter opens new doors to a very exciting area of computing. The chapter illustrates how information is actually transformed into transmittable bytes, and once again decoded after reaching its destination.

Chapter 4 ties together all the concepts in the previous chapters. Issues such as memory management and good programming practices are addressed. The authors introduce two methods of multitasking network calls using threads, cover issues in controlling I/O blocking, introduce unicasting, broadcasting, and multicasting protocols, and detail models for safe termination of communication. They also intersperse tips on object-oriented programming practices, without losing their primary objective, sockets. Readers interested in advanced topics in socket programming, such as buffer deadlocks, TCP/IP data structures, and the socket life cycle, will find chapter 5, aptly titled “Under the Hood,” to be a good introduction to these areas.

The book is well structured and easy to follow. Each time a new Java class is introduced, a short glossary for that class, including its constructors, operators, accessors, and mutators, is provided. All programming exercises are analyzed step by step, with explanations for each line of source code included by line number. Advanced concepts are based on more simple ones introduced in prec eding chapters. The authors have intimate knowledge of the various versions of Java, and briefly introduce some of the newer Java TCP/IP classes, such as the serializable and externalizable interfaces.

The authors’ Web site contains additional source code that supplements the book. At the end of each chapter there are excellent questions and programming problems, though the solutions are not readily available in the book, or on the publisher’s or authors’ Web site. I would have enjoyed testing my skills by checking one or more solutions to the exercises.

Programmers who comb through the details of this book and master the exercises will quickly find themselves on the way to advanced socket programming.

Reviewer:  Jessica Emami Review #: CR127092 (0306-0513)
Bookmark and Share
 
Java (D.3.2 ... )
 
 
TCP/ IP (C.2.2 ... )
 
 
Network Architecture And Design (C.2.1 )
 
Would you recommend this review?
yes
no
Other reviews under "Java": Date
Java for C/C++ programmers
Daconta M., John Wiley & Sons, Inc., New York, NY, 1996. Type: Book (9780471153245)
Apr 1 1997
Java programming explorer
Bartlett N., Leslie A., Simkin S., Coriolis Group Books, Scottsdale, AZ, 1996. Type: Book (9781883577810)
Apr 1 1997
The Java handbook
Naughton P., Osborne/McGraw-Hill, Berkeley, CA, 1996. Type: Book (9780078821998)
Apr 1 1997
more...

E-Mail This Printer-Friendly
Send Your Comments
Contact Us
Reproduction in whole or in part without permission is prohibited.   Copyright 1999-2024 ThinkLoud®
Terms of Use
| Privacy Policy