Catálogo de publicaciones - libros

Compartir en
redes sociales


SCJD Exam with J2SE 5

Andrew Monkhouse Terry Camerlengo

Second Edition.

Resumen/Descripción – provisto por la editorial

No disponible.

Palabras clave – provistas por la editorial

Software Engineering/Programming and Operating Systems

Disponibilidad
Institución detectada Año de publicación Navegá Descargá Solicitá
No detectada 2006 SpringerLink

Información

Tipo de recurso:

libros

ISBN impreso

978-1-59059-516-9

ISBN electrónico

978-1-4302-0107-6

Editor responsable

Springer Nature

País de edición

Reino Unido

Fecha de publicación

Información sobre derechos de publicación

© Apress 2006

Tabla de contenidos

Introduction

Andrew Monkhouse; Terry Camerlengo

In this chapter, we presented a broad overview of the Sun Certified Java Developer (SCJD) exam, as well as strategies you can use to meet your goal of passing the exam. We identified the areas that the exam covers, discussed the test itself, and offered some suggestions on taking it. We also provided a breakdown of the topics discussed in this book, integrated in the relevant J2SE 5 material.

With this information, you have already begun to prepare for the exam.

Congratulations! With about four weeks spent covering the issues set forth in this book, you should be able to take and pass the SCJD exam. In general, you should expect to spend a week on each of the four major topics: threading, Swing, networking, and the user interface. Of course, this will vary depending on your personal background. You now have a sense of what to expect. Good luck, study hard, and e-mail us at scjd@apress.com when you pass the exam.

Part 1 - Introduction and General Development Considerations | Pp. 3-9

Project Analysis and Design

Andrew Monkhouse; Terry Camerlengo

Spending a little bit of time up front in planning your project can pay big dividends in reducing total time spent on this assignment. Ensuring that your code is easy to read and maintain will win you better marks in this assignment, as well as more respect from your colleagues at work. And using the tools provided by Sun can make your submission far more professional.

We have introduced some of the features that will help you make a more professional submission, and assist you in your day-to-day life.

Part 1 - Introduction and General Development Considerations | Pp. 11-55

Project Overview

Andrew Monkhouse; Terry Camerlengo

In this chapter, we introduced the public interface of Denny’s DVDs rental-tracking program. We discussed the project requirements and each method of the interface that you will be responsible for implementing. All of the code for the sample application can be obtained from the Source Code section of the Apress web site (http://www.apress.com).

The new system should be accessible by multiple clients either across a network or locally. The GUI should be intuitive and easy-to-use, and the application must be thread-safe. The remainder of this book examines the requirements covered in this chapter. Denny’s DVDs rental-tracking program will evolve as each new concept is introduced.

Part 1 - Introduction and General Development Considerations | Pp. 57-67

Threading

Andrew Monkhouse; Terry Camerlengo

In this chapter, we discussed some of the possibilities available to you when using threads, and we pointed out some trouble spots to avoid. We discussed safe threading issues, threads and Swing, blocking, waiting, and a host of other topics.

The best way to understand threading is to design your threading scheme, make predictions about how it will function, and then test those predictions with the handy method in the Thread class, holdsLock(Object). Thread’s getState() and getStackTrace() methods can be very handy for checking what another thread is doing. If your threads aren’t behaving the way you expected them to, explicitly record your assumptions (we suggest writing them down) and then examine them one by one. Threading is a lot like grammar: There are a lot of rules, but eventually you develop a sense for what works and what doesn’t. (Or so I’m told.)

As you read the next chapters, please don’t hesitate to refer back to this chapter when needed.

Part 2 - Implementing a J2SE Project | Pp. 71-117

The DvdDatabase Class

Andrew Monkhouse; Terry Camerlengo

In this chapter we showed how to build classes that can read the data file and provide locking. We discussed some of the common pitfalls that can occur, and explained how to avoid them. We also presented several examples of design patterns, and examined how they can be used.

We used many of the techniques that you need to use in your Sun SCJD assignment, including reading and writing from random locations in files, and locking and releasing records. We also used many of the new techniques introduced in JDK 1.5, and introduced some of the new APIs.

One word of caution: As we mentioned in Chapter 3, we have made some parts of our sample assignment more difficult than the real assignment. You may find far simpler solutions for your Sun assignment than those presented here (and we strongly recommend you look for them). Similarly, some portions of the Sun assignment may be more difficult than what we have presented here. You will also note that there are methods in your Data class you must implement that we have not even mentioned; we believe we have provided you with the basic information you need to create these methods on your own.

Part 2 - Implementing a J2SE Project | Pp. 119-161

Networking with RMI

Andrew Monkhouse; Terry Camerlengo

Spending a little bit of time up front in planning your project can pay big dividends in reducing total time spent on this assignment. Ensuring that your code is easy to read and maintain will win you better marks in this assignment, as well as more respect from your colleagues at work. And using the tools provided by Sun can make your submission far more professional.

We have introduced some of the features that will help you make a more professional submission, and assist you in your day-to-day life.

Part 2 - Implementing a J2SE Project | Pp. 163-197

Networking with Sockets

Andrew Monkhouse; Terry Camerlengo

In this chapter, we discussed the Denny’s DVDs socket implementation. We also provided a brief overview of the different types of sockets, and the various types of TCP socket development strategies. We laid out the application protocol for our socket implementation and demonstrated the Command pattern with the help of Java enums. The choice of sockets as the network protocol in your exam solution should not be perceived as something esoteric and frightening that is to be avoided at all costs. Even though most students opt to not develop a socket solution, we believe that the choice isn’t any more challenging than an RMI solution and should be fairly straightforward, given the sample code base that accompanies this text. Sockets are a technology that underlies most networking protocols. Most of the cool new technologies, such as web services and EJBs, ultimately rely on sockets. As we have discussed, even RMI is built on top of sockets. So you would be well served to become acquainted with sockets, if only to help deepen your understanding of these other networking technologies. The next chapter covers the graphical user interface (GUI) for the Denny’s DVDs application.

Part 2 - Implementing a J2SE Project | Pp. 199-223

The Graphical User Interfaces

Andrew Monkhouse; Terry Camerlengo

A sound interface design will bridge the gap between the user and the system. By using solid design patterns, such as the Model-View-Controller (MVC) architectural paradigm, you can ensure that changes to the data display have minimal impact on the rest of the system. On a superficial level, the end user will most likely judge the quality of an application based on the functionally of its interface, so it is important to plan and design a quality front-end to a system.

In this chapter we introduced GUI design, and provided some examples of how you can combine various layout managers and components to achieve your desired design. It is important to realize that there is no “one right way” to develop a GUI, so you can use the techniques introduced here to develop GUIs that you believe will be usable for your instructions.

Part 2 - Implementing a J2SE Project | Pp. 225-292

Project Wrap-Up

Andrew Monkhouse; Terry Camerlengo

In this chapter we showed how to build classes that can read the data file and provide locking. We discussed some of the common pitfalls that can occur, and explained how to avoid them. We also presented several examples of design patterns, and examined how they can be used.

We used many of the techniques that you need to use in your Sun SCJD assignment, including reading and writing from random locations in files, and locking and releasing records. We also used many of the new techniques introduced in JDK 1.5, and introduced some of the new APIs.

One word of caution: As we mentioned in Chapter 3, we have made some parts of our sample assignment more difficult than the real assignment. You may find far simpler solutions for your Sun assignment than those presented here (and we strongly recommend you look for them). Similarly, some portions of the Sun assignment may be more difficult than what we have presented here. You will also note that there are methods in your Data class you must implement that we have not even mentioned; we believe we have provided you with the basic information you need to create these methods on your own.

Part 3 - Wrap-Up | Pp. 295-323