REVIEW - The Java/C++ Cross-reference Handbook

Title:

The Java/C++ Cross-reference Handbook

Author:

Frederick F. Chew

ISBN:

9780138483180

Publisher:

Prentice Hall (1998)

Pages:

460pp

Reviewer:

Brian Bramer

Reviewed:

August 1998

Rating:

★★☆☆☆

Although Java and C++ are syntactically similar (having common types, operators, control structures, etc.) learning either language (assuming a knowledge of the other) and converting applications between the languages is non-trivial. Many of the differences are quite subtle and have major implications, e.g. Java variables of non-primitive types contain a reference to an object, not the object itself.

This book is aimed at either Java or C++ programmers who need to learn or use the other language. It starts with language basics covering types, operators, control structures, arrays, parameter passing to functions/methods, etc. Class implementation is then described (basic syntax, constructors, access control, abstract classes, multiple inheritance and interfaces, etc.) followed by a discussion of run-time type identification, exception handling, I/O and threads. The final two chapters compare the Java AWT with the Microsoft MFC and networking under Java and UNIX. At each stage the languages are compared and contrasted, there are plenty of hints (including what C++ programmers need to 'unlearn') and example programs (available on the CD) to illustrate points made in the text.

I found the latter chapters most interesting, looking at problems common in real applications and how these are implemented in the two languages, e.g. a client/server example in C under BSD UNIX (using

fork(), socket(), listen()
, etc.) compared with the Java Network API. A useful book for a software engineer working with both languages and having to maintain and translate applications. I would not recommend it for someone wishing to learn either language.

Book cover image courtesy of Open Library.