Java Reference
In-Depth Information
package org.oreilly.javaGoodParts.examples.statistics;
import java.util.List;
import java.util.UUID;
* An interface that will allow passing all of the statistics from a single game
* to a {@link StatRecorder}, which will record the statistics for that game.
public interface BoxScore {
* Get a {@link List} of the names of the teams that played the game. There
* should be exactly two teams in the List.
* @return A {@link List} of {@link String} that are the names containing
* the two teams that played the game
List<String> getTeams();
* Get a {@link List} of the ids of the players who were in the game for the
* indicated team.
* @param forTeam
* The {@link String} name of the team for which the list of
* players returned plays
* @return a {@link List} of {@link UUID} identifying who played for the
* team in the game being reported
List<UUID> getPlayers(String forTeam);
* Get the position played by the particular player today.
* @param forPlayer
* The {@link UUID} which is the player id of the player whose
* position for the game is being reported
* @return the {@link Player.Position} played by the player in this game
* @throws DidNotPlayException
* if the player did not play in the game being reported
Player.Position getPosition(UUID forPlayer) throws DidNotPlayException;
* Gets a list of the at-bat results for a player.
Search WWH ::

Custom Search