Plutocracy Game Class Diagram
Plutocracy Game Class Diagram
Player
-bankBrand: BankBrand
-boardPosition: int
-centralBank: CentralBank
-game: Plutocracy
-karma: int
-ownerSites: ArrayList<Site>
-playerBank: Bank
-playerSymbol: char
+Player(name: String, bankBrand:
BankBrand, game: Plutocracy)
+addKarma(n: int)
+buyProperty()
+buyProperty(site: Site)
+buySite()
+buySite(site: Site)
+cashTransaction(amount: int)
+getBankBrand: BankBrand
+getBoardPosition(): int
+getKarma(): int
+getOwnerSites(): ArrayList<Site>
+getSymbol(): char
+goPastCentralBank()
+isPlayerBankrupt()
+isSiteOwnedBy(site: Site): boolean
+makeMove()
+setBoardPosition(int)
+upgradeProperty()
+upgradeProperty(site: Site)
Bank
#cash: int
#game: Plutocracy
#name: String
+Bank(game: Plutocracy)
+cashTransaction(amount: int)
+getCash(): int
+getName(): String
+setCash(amount: int)
+setName(name: String)
<<Enumerations>>
BankBrand
BA("Bank of America", inPath: String)
CB("CitiBank", inPath: String)
JP("JP Morgan", inPath: String)
ST("Santander", inPath: String)
WF("Wells Fargo", inPath: String)
-bankName: String
-path: String
-BankBrand(inBank: String, inPath: String)
+equalsBank(inBank: String): boolean
+returnImage(): String
+toString(): String
CentralBank
-globalTaxRate: int
-name: String
-totalCash: int
+CentralBank(game: Plutocracy)
+getTaxRate(): int
+setTaxRate(amount: int)
Cell
#cellname: String
#cellType: CellType
+Cell(type:CellType, name: String)
+getName(): String
+getType(): CellType
+setName(name: String)
+setType(type: CellType)
Plutocracy
-board: Gameboard
-boardCells: ArrayList<Cell>
-cb: CentralBank
-currentPlayerIndex: int
-doc: Document
-eventList: ArrayList<Event>
-nlist: NodeList
-nNode: Node
-numOfCells: int
-playerList: ArrayList<Player>
-random: int
+Plutocracy()
+actionPerformed(arg0: ActionEvent)
+getBoard: GameBoard
+getBoardCells: ArrayList<Cell>
+getCentralBank: CentralBank
+getCurrentPlayerIndex: int
+getEvent(player: Player): Event
+getPlayers: ArrayList<Player>
+loadBoardSquares(): ArrayList<Cell>
+run()
+setBoard(gameBoard: GameBoard)
+setup()
+updateGameBoard()
Site
-basePrice: int
-baseRent: int
-color: Color
-colorBonus: boolean
-owner: Bank
-properties: ArrayList<Property>
+Site(name: String, price: int, rent: int,
color: Color, game: Plutocracy)
+getBasePrice(): int
+getColor(): Color
+getOwner(): Bank
+getProperties(): ArrayList<Property>
+getRent(): int
+isUpgradeable(): boolean
+setBasePrice(price: int)
+setBaseRent(price: int)
+setColour(color: Colour)
+setIsUpgradable()
+setOwner(bank: Bank)
<<Enumeration>>
Colour
RED
ORANGE
YELLOW
GREEN
BLUE
INDIGO
VIOLET
<<Enumeration>>
CellType
BLANK
CENTRAL_BANK
RANDOM_EVENT
SITE
TAX
Event
#isOptional: boolean
#text: String
#karmaLowerBound: int
#karmaUpperBound: int
+Event(isOptional: boolean, text: String,
karmaLowerBound: int,
karmaUpperBound: int)
+getKarmaLower(): int
+getKarmaUpper(): int
+getText(): String
+isOptional(): boolean
+setKarmaLower(karmaLowerBound: int)
+setKarmaUpper(karmaUpperBound: int)
setText(text: String)
MandatoryEvent
-cashChange: int
-karmaChange: int
+MandatoryEvent(text: String, cash: int,
karma: int, karmaUp: int, karmaLow: int)
+getCashChange(): int
+getKarmaChange(): int
+setCashChange(cashChange: int)
+setKarmaChange(karmaChange: int)
OptionalEvent
-cashChangeNo: int
-cashChangeYes: int
-karmaChangeNo: int
-karmaChangeYes: int
+OptionalEvent(text: String, cashYes: int,
karmaYes: int, karmaUp: int, karmaLow:
int, cashNo: int, karmaNo: int)
+getCashChangeNo(): int
+getCashChangeYes(): int
+getKarmaChangeNo(): int
+getKarmaChangeYes(): int
+setCashChangeNo(cashChange: int)
+setCashChangeYes(cashChange: int)
+setKarmaChangeNo(karmaChange: int)
+setKarmaChangeYes(karmaChange: int)
Main
+main(args String[])
Property
+RENT_PERCENTAGE: double
+UPGRADE_PERCENTAGE: double
+Property(value: int)
-propertyType: PropertyType
-propertyValue: int
+getPropertyType(): PropertyType
+getRentContribution(): int
+getUpgradeCost(): int
+setPropertyType(propertyType:
PropertyType)
+upgrade()
<<Enumeration>>
PropertyType
CONFERENCE_CENTRE
OFFICE
plutocracyGUI.resources plutocracyGUI.resources.banks xmlFiles
Dialog
+getHowManyPlayers(min: int, max: int):
int
+getPlayer(game: Plutocracy): Player
+getPlayerBank(game: Plutocracy):
BankBrand
+getPlayerName(game: Plutocracy):
String
+showBankruptConfirmation()
+showBuyPropertyConfirmation(site:
Site, playerCash: int)
+showBuySiteConfirmation(site: Site,
playerCash: int)
+showEvent(event: MandatoryEvent)
+showEvent(event: OptionalEvent):
boolean
+showPassCentralBankConfirmation(cash
: int, playerCash: int)
+showRent( amount: int, owner: Bank,
playerCash: int)
+showTaxPaid(amount: int, playerCash:
int)
+showTaxPaid(amount: int, description:
String, playerCash: int)
+showTaxSkipOption(amount: int):
boolean
+showTaxSkipOption(amount: int,
description: String): boolean
+siteOptionBox(game: Plutocracy, site:
Site, player: Player)
javax.swing
SiteInfoBox
-pnlInfo: JPanel
-siteColour: JLabel
-siteName: JLabel
-siteOwner: JLabel
-sitePrice: JLabel
-siteProperty: JLabel
-siteRent: JLabel
+SiteInfoBox(site: Site)
PlayerInfoBox
-player: Player
-playerBank: JLabel
-playerCash: JLabel
-playerIcon: JLabel
-playerImage: JLabel
-playerName: JLabel
-pnlInfo: JPanel
-siteOwned: JTextArea
+PlayerInfoBox(game: Plutocracy,
playerNumber: int)
GameBoard
+GameBoard(game: Plutocracy)
+getBtnEndTurn(): JButton
+getClickedSite: SiteInfoBox
+KillSiteInfoBox()
+setBtnEndTurn(btnEndTurn: JButton)
+setClickedSite(clickedSite: SiteInfoBox)
+update()
InfoBox
+InfoBox(title: String)
GameLog
-allTestPane: JTestPane
-allTextpaneScroll: JScrollPane
-context: StyleContext
-document1: StyledDocument
-document2: StyledDocument
-document3: StyledDocument
-document4: StyledDocument
-logTabbedPane: JTabbedPane
-propertyTextpane: JTextPane
-propertyTextPaneScroll: JScrollPane
-rentTextpane: JTextPane
-rentTextpaneScroll: JScrollPane
-style: Style
-taxTextpane: JTextPane
-taxTextpaneScroll: JScrollPane
+GameLog()
+outputMessageToLogBox(logType:
logType, message: String)
<<Enumeration>>
logType
GLOBAL
RENT
SITE
TAX
Inherits
javax.swing.JFrame
Inherits
javax.swing.JFrame
Inherits
Inherits
Inherits
Inherits
1
1
1
2..*
Defines the type of Cell
Inherits
1
1
1
1..*
1
*
plutocracyGUI
Inherits
Inherits
Plutocracy
Class Diagram
Inherits
Javax.swing.JDialog
1
1..*
plutocracy