Understanding SQL & Java Together: A Guide to SQLJ, JDBC, and Related Technologies

Appendix I: The PlayingCard Classes

1.1 Introduction

This appendix contains several classes that were developed piecemeal in Chapter 2. These classes are PlayingCard, PlayingCardAceLow, PlayingCardEnum, and Deck. The comments that introduce the variables and methods may seem verbose. They are structured comments used by the javadoc tool to generate HTML documentation for these classes.

1.2 The PlayingCard Class

import java.io.*;import java.util.*;/** * This class represents a playing card. * * @author   Andrew Eisenberg * @version  1.0 * @since    JDK 1.1.6 * */<a name="1182"></a><a name="IDX-478"></a>public class PlayingCard  implements Serializable {   /**    * The suit of Hearts    *    */   final public static int HEART    =  0;   /**    * The suit of Diamonds    *    */   final public static int DIAMOND  =  1;   /**    * The suit of Spades    *    */   final public static int SPADE    =  2;   /**    * The suit of Clubs    *    */   final public static int CLUB     =  3;   /**    * An indication that no suit is applicable to this card.    *    */ ...

UNLIMITED FREE
ACCESS
TO THE WORLD'S BEST IDEAS

SUBMIT
Already a GlobalSpec user? Log in.

This is embarrasing...

An error occurred while processing the form. Please try again in a few minutes.

Customize Your GlobalSpec Experience

Category: Laser Pointers
Finish!
Privacy Policy

This is embarrasing...

An error occurred while processing the form. Please try again in a few minutes.