Items related to The Java/C++: Cross-Reference Handbook

The Java/C++: Cross-Reference Handbook - Softcover

 
9780138483180: The Java/C++: Cross-Reference Handbook

Synopsis

An exceptionally practical reference for any developer working with Java and C++++ contains direct, unbiased comparisons between Java and C++++ keywords, constructs, features, I/O, container, and exception classes. Original. (All Users).

"synopsis" may belong to another edition of this title.

About the Author

FREDERICK F. CHEW is an Information Technology Engineer for Hewlett-Packard in Palo Alto, California, and is a Science major graduate from the University of Santa Clara. He acts as in-house instructor for object-oriented technologies such as Java and C++. In addition, he is a frequent contributor of technical articles for the hp-ux/usr magazine, a publication of INTEREX.

From the Back Cover

  • Java( vs. C++: Direct, unbiased comparisons
  • Slash your learning curve!
  • Easy Q&A format
  • Extensive sample code
  • Java™ for C++ developers
  • C++ for Java™ developers

The nuts-and-bolts Java™/C++ comparison you've been waiting for!

C++ developers: Learn Java now! Java developers: Learn C++ now!

If you know either language, leverage what you already know to become an expert on both Java and C++! Slash your learning curve with this exceptionally practical reference, full of easy-to-use Q&As, sample code, and unbiased comparisons that'll make you productive fast. Discover:

  • Techniques you already know that'll keep working with little or no change
  • Subtle but critical differences between C++ and Java
  • Habits you'd better "unlearn" fast

Through real-world examples, compare how Java and C++ handle:

  • Literals, keywords, operators, and basic constructs
  • Environmental differences
  • Java and C++ classes, inheritance, polymorphism, and exception handling
  • Obtaining runtime type information about objects

Review the application services available to Java applications, and how they compare to C++ equivalents in UNIX and Windows NT™. Learn how the C++ iostream class framework compares with the Java stream classes of package java.io. Discover the basics of multiprocessing and multithreading in both Java and C++. Compare event trapping in Java and NT C++ message-driven environments, and see how Java windows management stacks up against OSF/Motif. Compare sockets, client/server programming, and TCP/IP internetworking in Java and C++.

The CD-ROM includes more than 100 sample programs, plus 32-bit Windows versions of the Java Developer's Kit (JDK) version 1.1.3™ and trial versions of Symantec's Visual Cafe™ and Visual Page™.

Whether you're migrating to Java, a Java programmer being asked to work in C++, or even a procedural programmer who wants to learn both languages, you won't find a more practical reference than The Java/C++ Cross-Reference Handbook.

From the Inside Flap

Preface


The Story Behind this Book

At the time of this writing, I have been an employee of the Hewlett-Packard Company for over fifteen years. Over the years I have worked in many entities, played different roles and have experienced many changes within the company. My technical literary journey started when I had joined HP's North American Response Center around 1987, where I became a member of a personal computer support team. During that period, I had contributed articles to the now defunct HP PC Communicator, a pocket-size journal that was delivered to HP customers. Since then, I have written articles for HP Professional, Interact and hp-ux/usr magazines. The latter two are publications of INTEREX, an organization representing all HP trade customers.

During that period of my career, I had also joined an internal company program called "HP AHEAD." HP AHEAD is an after-hours training program to benefit HP employees, a sort of community college within the company for those who work around the San Francisco Bay Area. The program is a great way for employees with special expertise to share their knowledge and broaden their horizons. For myself, I have been engaged in after-hours instruction for over ten years and have designed, developed and delivered five courses. The latest and most recent work is a comprehensive course I call Objects11: C++ Programming Fundamentals, a course to help the experienced C programmer enter the world of C++ programming. Now, the reader might be wondering what technical instruction and technical writing has to do with this book. For some years, I have dreamt of becoming an author, but I was not sure if I was up to the task. In many ways, writing a book is like developing a course, except the discipline, effort and the risks are immensely greater. Compared to writing an article, writing a book is an effort of a titanic scale. In January 1995, I had an article about C++ exception handling published in INTEREX's hp-ux/usr magazine. Shortly after the article's release, Pat Pekary of Hewlett-Packard Professional Books had given me a call to congratulate me on the article. Up to then, I did not know, nor had I ever worked with Pat. The amazing thing about the entire conversation was that she had actually encouraged me to write a book! It is extremely rare in life that someone you do not know actually approaches you and tells you that you have "the right stuff." Too often, individuals with great potential are discouraged or denied the opportunity to excel because they are not chosen by, or part of, a special nobility. I thank Pat for opening the door to make my dream of becoming an author possible. In addition, I hope my example will lend encouragement and hope to other individuals with the same dreams.

Acknowledgments

For myself, writing this book was a great, personal mission requiring an extraordinary amount of planning, patience, and persistence. I believe any author will testify that these virtues are absolutely necessary for success. However, despite all of the hard work of the individual author, it is the team effort of all concerned who make the book a reality. Toward this effort, I would like to acknowledge the hard-working people at Prentice Hall for making the mission a wonderful success. My thanks to Nicholas Radhuber for keeping the production of the book on track, to Mary Franz for making the book the most customer-friendly product it could be, and to Miles Williams for his imaginative and witty idea of the graphic that adorns the front cover of the book. Last, but not least, my thanks goes to all who have reviewed or given feedback to improve the content and clarity of the book.

The Audience for the Book

This book is for the software professional who has anything to do with software development: development, instruction, learning or consulting. I have written this book in the same spirit that I developed and taught my C++ course. In other words, this work is to serve as a bridge to help seasoned professionals of an established technology (C++) embrace and become proficient in a rising technology (Java).
To say that Java is merely a rising technology is probably an understatement. In the very short time since its formal release, there has been tremendous interest in this Internet technology. Businesses that are interested in publicizing their products and services on the World Wide Web are competing to find Java-knowledgeable developers. For software professionals, the possibilities for career growth and financial gain have never been better.
In this day and age, a software professional cannot afford to be complacent, otherwise he will be left behind in the employment marketplace. Unfortunately, many of the new technologies are not easily learned or mastered. It takes initiative and long-term dedication to become proficient at a new skill. There are those who would give the impression that Java is simply another dialect of C++. However, beyond the many syntactic similarities, writing a meaningful Java application with only C++ experience is not trivial. There are many C++ constructs, semantics and practices that do not apply to the Java environment. Conversely, there are elements in Java that have no equivalents in C++.
However, an experienced C++ developer is in a good position to integrate Java into his technical skill set. It is mostly a matter of unlearning some things, understanding the equivalent things, learning some new things, changing habits and a lot of practice. The purpose of this book is to address these aspects and to demonstrate the differences by example. I believe this is where my book differs from other Java books: I do not merely talk about the differences between Java and C++, I demonstrate them. I believe this approach will shorten the learning curve tremendously and help the developer internalize the subtle, but important, differences between the two languages.
For the experienced C language developer who has yet to enter the world of object-oriented programming with either C++ or Java, this book will guide the developer into both languages. Learning both of these popular languages will give the traditional, procedural language programmer valuable skills in the technical marketplace.

The Organization of the Book

The heart of the book compares the language features of C++ and Java. The first six chapters discuss and demonstrate the syntactic and semantic features of both languages. Chapter 1 gives an overview of the environmental differences surrounding a C++ application versus a Java application. Chapter 2 discusses the literals, keywords, operators and basic constructs of both languages. Chapter 3 focuses on how each language implements the notion of the class. Chapter 4 introduces how inheritance is supported in both languages. In addition, this chapter discusses supporting constructs like member access restrictions, virtual functions and abstract classes. Chapter 5 discusses how to obtain run-time type information about an object in either language. Chapter 6 covers the exception handling mechanism in both languages. This chapter demonstrates how to regulate the flow of control when exceptions are thrown. The last four chapters go beyond the standard features of the languages to compare services typically required by any application. Such services include functions or classes to support file input-output, window control layout and network programming. The comparisons span multiple platforms, where a Java example is compared to a popular, native C or C++ example from UNIX or Microsoft Windows NT. Chapter 7 compares the C++ iostream class framework with the Java stream classes of package java.io. Chapter 8 discusses multiprocessing versus multithreading, with the main focus on how to do the latter in Java. Chapter 9 discusses how events could be trapped in message-driven environments such as Microsoft Windows NT and Java. In addition, a major portion of the chapter is devoted to window layout management in Java as compared to OSF Motif. Chapter 10 discusses and demonstrates how to do client-server programming with sockets in both Java and C.


The Sample Programs

The great majority of the Java and C++ sample programs were conceived from a Microsoft Windows NT® environment (version 3.51 or higher). All of these programs come with sources, bytecode files or executables. All of these samples should work fine in the Windows 95® environment. At the time of the actual writing, all of the Java samples were built with Symantec Caf® 1.0 and version 1.0.2 of the Java Developers Kit® (JDK). Since the book had entered production, the JDK has undergone a major revision to 1.1. All of the Java samples have been tested with JDK 1.1.1 and, with the exception of a handful, have been verified to work with the new version. For the corner cases, version 1.1.1-specific examples have been provided on the media. The great majority of the C++ samples from Windows NT® were composed with Microsoft Visual C++ 4.0®. Since this version of the Microsoft compiler does not support all of the ISO/ANSI exception handling specifications, there are a few examples that are more suited to the Borland C++ 5.0® compiler. The Borland-specific example is noted as such in the comment header at the top of the source file. A small handful of C sample programs were created on a HP-UX 9.0 environment. These programs come with sources and shell scripts to create the executables. The sources and scripts must be network copied to a UNIX environment with a utility like FTP. The OSF Motif®-based examples require certain development libraries to be in place before the executables can be built. For directory structure and installation instructions, please refer to the section entitled About the Software at the end of this book.

Interesting Web Sites

There is certainly no shortage of information about Java from different Internet sources.

About the Icons

Sprinkled throughout the book are graphical icons that serve to emphasize certain passages in the text. Such icons may draw the reader's attention to warnings, recommended practices or simply the fact that a program listing is available from the distribution media. Below are the icons and their meaning:

This icon is a warning. In other words, be watchful of pitfalls.

This icon is a note or observation. The connotation is neither negative nor positive.

This icon represents enlightenment. The point emphasized is a recommended software engineering practice.

The program source code is available on the CD-Rom. v

The Java/C++ Cross-Reference Handbook # Contents #

The Java/C++ Cross-Reference Handbook # Contents # xi

The Java/C++ Cross-Reference Handbook # Preface #

The Java/C++ Cross-Reference Handbook # Preface # xvi About the Author


Frederick F. Chew is a graduate of the University of Santa Clara and has a B.S. degree in mathematics. He has been an employee of the Hewlett-Packard Company for over fifteen years and is currently an Information Technology Engineer with Hewlett-Packard's Asia-Pacific Geography. He is also a C++ instructor with the HP AHEAD program and is a contributor of articles on object-oriented software development to INTEREX's hp-ux/usr magazine.

xvii xviii

"About this title" may belong to another edition of this title.

  • PublisherPrentice Hall Ptr
  • Publication date1997
  • ISBN 10 0138483183
  • ISBN 13 9780138483180
  • BindingPaperback
  • LanguageEnglish
  • Number of pages446

Buy Used

Condition: Very Good
View this item

FREE shipping within U.S.A.

Destination, rates & speeds

Buy New

View this item

US$ 33.84 shipping from United Kingdom to U.S.A.

Destination, rates & speeds

Search results for The Java/C++: Cross-Reference Handbook

Stock Image

Chew, Frederick F.
Published by Prentice Hall Ptr, 1997
ISBN 10: 0138483183 ISBN 13: 9780138483180
Used Softcover

Seller: Decluttr, Kennesaw, GA, U.S.A.

Seller rating 5 out of 5 stars 5-star rating, Learn more about seller ratings

Condition: Very Good. 1720461021. 7/8/2024 5:50:21 PM. Seller Inventory # U9780138483180

Contact seller

Buy Used

US$ 11.20
Convert currency
Shipping: FREE
Within U.S.A.
Destination, rates & speeds

Quantity: 1 available

Add to basket

Stock Image

Chew, Frederick F.
Published by Prentice Hall Ptr, 1997
ISBN 10: 0138483183 ISBN 13: 9780138483180
Used paperback

Seller: HPB-Red, Dallas, TX, U.S.A.

Seller rating 5 out of 5 stars 5-star rating, Learn more about seller ratings

paperback. Condition: Good. Connecting readers with great books since 1972! Used textbooks may not include companion materials such as access codes, etc. May have some wear or writing/highlighting. We ship orders daily and Customer Service is our top priority! Seller Inventory # S_388935417

Contact seller

Buy Used

US$ 10.98
Convert currency
Shipping: US$ 3.75
Within U.S.A.
Destination, rates & speeds

Quantity: 1 available

Add to basket

Stock Image

Frederick F. Chew
Published by Prentice Hall Ptr, 1997
ISBN 10: 0138483183 ISBN 13: 9780138483180
Used Paperback

Seller: ThriftBooks-Atlanta, AUSTELL, GA, U.S.A.

Seller rating 5 out of 5 stars 5-star rating, Learn more about seller ratings

Paperback. Condition: Good. No Jacket. Pages can have notes/highlighting. Spine may show signs of wear. ~ ThriftBooks: Read More, Spend Less 2.1. Seller Inventory # G0138483183I3N00

Contact seller

Buy Used

US$ 14.96
Convert currency
Shipping: FREE
Within U.S.A.
Destination, rates & speeds

Quantity: 1 available

Add to basket

Stock Image

Chew, Frederick F.
ISBN 10: 0138483183 ISBN 13: 9780138483180
Used Softcover

Seller: a2zbooks, Burgin, KY, U.S.A.

Seller rating 4 out of 5 stars 4-star rating, Learn more about seller ratings

Softcover. Condition: Very Good. Edition Unstated. All the books pages appear to be clean. Light shelf and corner wear to the books cover. Binding is in good condition. Book comes with a CD. Book has a stain on the back of book, top left corner. The Stain starts at page 409 and goes to the end of the book. The stain is very small. 446 pp. Quantity Available: 1. Category: Computers & Internet; ISBN: 0138483183. ISBN/EAN: 9780138483180. Pictures of this item not already displayed here available upon request. Inventory No: ABE540000169. Seller Inventory # ABE540000169

Contact seller

Buy Used

US$ 32.00
Convert currency
Shipping: US$ 6.35
Within U.S.A.
Destination, rates & speeds

Quantity: 1 available

Add to basket

Stock Image

Chew, Frederick F.
Published by Prentice Hall Ptr, 1997
ISBN 10: 0138483183 ISBN 13: 9780138483180
Used Softcover

Seller: Phatpocket Limited, Waltham Abbey, HERTS, United Kingdom

Seller rating 5 out of 5 stars 5-star rating, Learn more about seller ratings

Condition: Good. Your purchase helps support Sri Lankan Children's Charity 'The Rainbow Centre'. Ex-library, so some stamps and wear, but in good overall condition. Our donations to The Rainbow Centre have helped provide an education and a safe haven to hundreds of children who live in appalling conditions. Seller Inventory # Z1-C-004-03169

Contact seller

Buy Used

US$ 26.45
Convert currency
Shipping: US$ 14.40
From United Kingdom to U.S.A.
Destination, rates & speeds

Quantity: 1 available

Add to basket

Stock Image

Chew, Frederick F.
Published by Prentice Hall Ptr, 1997
ISBN 10: 0138483183 ISBN 13: 9780138483180
New Paperback

Seller: dsmbooks, Liverpool, United Kingdom

Seller rating 4 out of 5 stars 4-star rating, Learn more about seller ratings

Paperback. Condition: New. New. book. Seller Inventory # D7S9-1-M-0138483183-6

Contact seller

Buy New

US$ 114.65
Convert currency
Shipping: US$ 33.84
From United Kingdom to U.S.A.
Destination, rates & speeds

Quantity: 1 available

Add to basket