A.4. The Games Class

 // Games.java package nfl.original; import java.io.*; import java.util.*; /** All games that have been played, and summary * information about them */ public class Games { public static final int GAMES_IN_SEASON = 16; private List gameList = new ArrayList(250); /** Returns all games played as a List */ public List getGameList() {return gameList; } /** Sets the list of played games */ public void setGameList(List g) {gameList = g; } /** A handle to the Teams object is used for determining * conference & division membership. */ private Teams teams = Teams.getHandle(); private static Games games = new Games(); public static Games getHandle() {return games; } /** Constructor for the Games object. */ private Games() { // Week ...

Get J2EE™ and JAX™: Developing Web Applications and Web Services now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.