|
|||||||||
| Home >> All >> org >> dma >> ihm >> game >> league >> [ std overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
org.dma.ihm.game.league.std
Class StdLeague

java.lang.Objectorg.dma.ihm.game.league.League
org.dma.ihm.game.league.std.StdLeague
- All Implemented Interfaces:
- java.lang.Comparable, java.io.Serializable
- public class StdLeague
- extends org.dma.ihm.game.league.League
StdLeague Implementation of a standard League after the model of the lovely country called Switzerland ;-)
- Stdleague may have n teams.
- The teams will play n1 times against each other (once at home, once away) called regular season.
- After the regular season the top teams play Playoffs, the bottom teams Playouts.
- The playoff/outs work with n2 "levels" (quarter, semi- and final or more)
- If 0 is passed by the constructor as starting level of playoffs/outs none are played.
| Field Summary | |
private org.dma.ihm.game.calendar.GameCalendarHelper |
gameCalendarHelper
Game calendar helper to place matches in the calendar |
private org.dma.ihm.game.calendar.GameCalendarHelper |
gameCalendarPlayoffHelper
Game calendar helper to place Playoff matches in the calendar |
private org.dma.ihm.game.calendar.GameCalendarHelper |
gameCalendarPlayoutHelper
Game calendar helper to place Playouts matches in the calendar |
private int |
multiRounds
How many times play teams against each other (1 = 1 home and 1 away game) |
private java.util.Vector |
otherLeagueElements
Other Elements (i.E. |
private static java.lang.String |
playoffGameDays
Gamedays while playoff/outs |
private int |
playoffLevels
Playofflevels |
private StdPlayoffs[] |
playoffs
Playoffs |
private int |
playoffsBestOf
Playoff are bestOf n |
private boolean |
playoffsFinished
Helper to mark finished playoffs |
private org.dma.ihm.game.league.helper.LeagueElementGroup |
playoffsGroup
Playoffs group |
private int |
playoutLevels
Playoutlevels |
private StdPlayoffs[] |
playouts
Playouts |
private int |
playoutsBestOf
Playouts are bestOf n |
private boolean |
playoutsFinished
Helper to mark finished playouts |
private org.dma.ihm.game.league.helper.LeagueElementGroup |
playoutsGroup
Playouts group |
private StdRegularSeason |
regularSeason
Regular season |
private static java.lang.String |
regularSeasonGameDays
Gamedays while regular season |
private org.dma.ihm.game.league.helper.LeagueElementGroup |
regularSeasonGroup
Regular Seasons group |
| Fields inherited from class org.dma.ihm.game.league.League |
leagueOwner, name, rank, teams |
| Constructor Summary | |
StdLeague(java.lang.String leagueName,
int ranking,
org.dma.ihm.game.team.Team[] teams,
int multiRounds,
int playoffLevels,
int playoffsBestOf,
int playoutLevels,
int playoutsBestOf)
Constructor with leaguename, rank in the owner, teams, multirounds, playoffLevels, playoffbestOf, playoutLevels, playoutBestOf. |
|
| Method Summary | |
void |
addLeaguePlayoffElement(org.dma.ihm.game.league.helper.LeagueElement leagueElement)
Add playoffs (League Playoffs) to this league |
void |
generatePlayoffsLevel(int level)
Creates the level'th round of the playoffs |
void |
generatePlayoutsLevel(int level)
Like playoffs, but different ;-)) |
void |
generateRegularSeason()
Creates the matches of the regular season, and places the matches in the game calendar. |
java.util.Vector |
getLeagueElementGroups()
Returns the LeagueElementGroups of this League |
java.util.Vector |
getLeagueElements()
Returns all leagueElements |
org.dma.ihm.game.team.Team |
getLeagueFirstTeam()
Returns the winner of this league (called by leagueOwner to i.E. |
org.dma.ihm.game.team.Team |
getLeagueLastTeam()
Returns the loser of this league (called by leagueOwner to i.E. |
int |
getMultiRounds()
Gets the multiRounds attribute of the StdLeague object |
int |
getPlayoffLevels()
Gets the playoffLevels attribute of the StdLeague object |
int |
getPlayoffsBestOf()
Gets the playoffsBestOf attribute of the StdLeague object |
int |
getPlayoutLevels()
Gets the playoutLevels attribute of the StdLeague object |
int |
getPlayoutsBestOf()
Gets the playoutsBestOf attribute of the StdLeague object |
private StdLeagueOwner |
getStdLeagueOwner()
Returns the owner of this league |
boolean |
isFirstTeamKnown()
Checks if first team (winner) is known (so we could start the leaguePlayoffs |
boolean |
isLastTeamKnown()
Checks if last team (loser) is known (so we could start the leaguePlayoffs |
void |
leaguePlayoffsFinished()
Sets playoffFinished flag to true and informes the owner |
void |
leaguePlayoutsFinished()
Sets playoutsFinished flag to true and informes the owner |
void |
newSeason()
Resets league, and generates the regular Season |
| Methods inherited from class org.dma.ihm.game.league.League |
compareTo, getDescription, getLeagueOwner, getName, getPlayers, getPlayerStats, getRank, getSortValue, getTeams, getTeamStats, isTeamOfLeague, replaceTeam, setLeagueOwner, toString |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
gameCalendarHelper
private org.dma.ihm.game.calendar.GameCalendarHelper gameCalendarHelper
- Game calendar helper to place matches in the calendar
gameCalendarPlayoffHelper
private org.dma.ihm.game.calendar.GameCalendarHelper gameCalendarPlayoffHelper
- Game calendar helper to place Playoff matches in the calendar
gameCalendarPlayoutHelper
private org.dma.ihm.game.calendar.GameCalendarHelper gameCalendarPlayoutHelper
- Game calendar helper to place Playouts matches in the calendar
regularSeasonGameDays
private static final java.lang.String regularSeasonGameDays
- Gamedays while regular season
- See Also:
- Constant Field Values
playoffGameDays
private static final java.lang.String playoffGameDays
- Gamedays while playoff/outs
- See Also:
- Constant Field Values
regularSeason
private StdRegularSeason regularSeason
- Regular season
playoffs
private StdPlayoffs[] playoffs
- Playoffs
playouts
private StdPlayoffs[] playouts
- Playouts
otherLeagueElements
private java.util.Vector otherLeagueElements
- Other Elements (i.E. LeaguePlayoffs) are grouped in the playouts group !
regularSeasonGroup
private org.dma.ihm.game.league.helper.LeagueElementGroup regularSeasonGroup
- Regular Seasons group
playoffsGroup
private org.dma.ihm.game.league.helper.LeagueElementGroup playoffsGroup
- Playoffs group
playoutsGroup
private org.dma.ihm.game.league.helper.LeagueElementGroup playoutsGroup
- Playouts group
playoffLevels
private int playoffLevels
- Playofflevels
playoffsBestOf
private int playoffsBestOf
- Playoff are bestOf n
playoutLevels
private int playoutLevels
- Playoutlevels
playoutsBestOf
private int playoutsBestOf
- Playouts are bestOf n
multiRounds
private int multiRounds
- How many times play teams against each other (1 = 1 home and 1 away game)
playoffsFinished
private boolean playoffsFinished
- Helper to mark finished playoffs
playoutsFinished
private boolean playoutsFinished
- Helper to mark finished playouts
| Constructor Detail |
StdLeague
public StdLeague(java.lang.String leagueName, int ranking, org.dma.ihm.game.team.Team[] teams, int multiRounds, int playoffLevels, int playoffsBestOf, int playoutLevels, int playoutsBestOf)
- Constructor with leaguename, rank in the owner, teams, multirounds,
playoffLevels, playoffbestOf, playoutLevels, playoutBestOf. Doesn't create
new matches ! See reset function.
| Method Detail |
getMultiRounds
public int getMultiRounds()
- Gets the multiRounds attribute of the StdLeague object
getPlayoffLevels
public int getPlayoffLevels()
- Gets the playoffLevels attribute of the StdLeague object
getPlayoffsBestOf
public int getPlayoffsBestOf()
- Gets the playoffsBestOf attribute of the StdLeague object
getPlayoutLevels
public int getPlayoutLevels()
- Gets the playoutLevels attribute of the StdLeague object
getPlayoutsBestOf
public int getPlayoutsBestOf()
- Gets the playoutsBestOf attribute of the StdLeague object
newSeason
public void newSeason()
- Resets league, and generates the regular Season
getStdLeagueOwner
private StdLeagueOwner getStdLeagueOwner()
- Returns the owner of this league
generateRegularSeason
public void generateRegularSeason()
- Creates the matches of the regular season, and places the matches in the
game calendar. Important: Also places a event in the calendar, which will
create playoff/outs (if they are wanted, else directly the end of them).
generatePlayoffsLevel
public void generatePlayoffsLevel(int level)
- Creates the level'th round of the playoffs
- If there is only one round to play (final) or the it's the first round it takes the teams of the league directly, else out of the winners of the last playoff round.
generatePlayoutsLevel
public void generatePlayoutsLevel(int level)
- Like playoffs, but different ;-))
getLeagueFirstTeam
public org.dma.ihm.game.team.Team getLeagueFirstTeam()
- Returns the winner of this league (called by leagueOwner to i.E. start the
leaguePlayofffs
getLeagueLastTeam
public org.dma.ihm.game.team.Team getLeagueLastTeam()
- Returns the loser of this league (called by leagueOwner to i.E. start the
leaguePlayofffs
isFirstTeamKnown
public boolean isFirstTeamKnown()
- Checks if first team (winner) is known (so we could start the
leaguePlayoffs
isLastTeamKnown
public boolean isLastTeamKnown()
- Checks if last team (loser) is known (so we could start the leaguePlayoffs
leaguePlayoutsFinished
public void leaguePlayoutsFinished()
- Sets playoutsFinished flag to true and informes the owner
leaguePlayoffsFinished
public void leaguePlayoffsFinished()
- Sets playoffFinished flag to true and informes the owner
addLeaguePlayoffElement
public void addLeaguePlayoffElement(org.dma.ihm.game.league.helper.LeagueElement leagueElement)
- Add playoffs (League Playoffs) to this league
getLeagueElements
public java.util.Vector getLeagueElements()
- Returns all leagueElements
getLeagueElementGroups
public java.util.Vector getLeagueElementGroups()
- Returns the LeagueElementGroups of this League
|
|||||||||
| Home >> All >> org >> dma >> ihm >> game >> league >> [ std overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC