net.jetrix.winlist
Class GameResult

java.lang.Object
  extended by net.jetrix.winlist.GameResult

public class GameResult
extends Object

The result of a game.

Version:
$Revision: 426 $, $Date: 2004-10-03 19:32:15 +0200 (dim., 03 oct. 2004) $
Author:
Emmanuel Bourg

Constructor Summary
GameResult()
           
 
Method Summary
 Channel getChannel()
          Return the channel associated to this result.
 Date getEndTime()
          Return the date of the end of the game.
 Collection<GamePlayer> getGamePlayers()
          Return the list of players involved in the game.
 Collection<GamePlayer> getPlayersAtRank(int rank)
          Return the players that finished the game at the specified rank.
 Date getStartTime()
          Return the date of the beginning of the game.
 int getTeamCount()
          Return the number of teams in this game.
 void setChannel(Channel channel)
           
 void setEndTime(Date endTime)
           
 void setStartTime(Date startTime)
           
 void update(User user, boolean isWinner)
          Update the result of the game by indicating if the specified user won or not.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GameResult

public GameResult()
Method Detail

getStartTime

public Date getStartTime()
Return the date of the beginning of the game.


setStartTime

public void setStartTime(Date startTime)

getEndTime

public Date getEndTime()
Return the date of the end of the game.


setEndTime

public void setEndTime(Date endTime)

getChannel

public Channel getChannel()
Return the channel associated to this result. It may be used to send a message in the channel reporting the new scores of the players.


setChannel

public void setChannel(Channel channel)

getGamePlayers

public Collection<GamePlayer> getGamePlayers()
Return the list of players involved in the game. The collection contains instances of GamePlayer.


update

public void update(User user,
                   boolean isWinner)
Update the result of the game by indicating if the specified user won or not.


getPlayersAtRank

public Collection<GamePlayer> getPlayersAtRank(int rank)
Return the players that finished the game at the specified rank.


getTeamCount

public int getTeamCount()
Return the number of teams in this game.



Copyright © 2001-2008 Emmanuel Bourg. All Rights Reserved.