Klassendiagramm
2015-04-26 22:06:23 5 举报
Klassendiagramm(类图)是一种用于描述软件系统中类及其相互关系的图形表示方法。它展示了系统中各个类的属性、方法和关系,有助于开发人员更好地理解系统的结构和功能。在类图中,每个类用一个矩形表示,矩形内包含类名和类的属性和方法。类之间的关系通过箭头表示,箭头的类型表示关系的性质,如继承、关联、聚合等。通过类图,开发人员可以更容易地识别系统中的潜在问题,优化设计并提高代码的可维护性。总之,类图是软件工程中一种非常重要的工具,有助于提高开发效率和产品质量。
作者其他创作
大纲/内容
Player
-name: String-sweets: int-race: String-bigFigures: int-smallFigures: int-buildingcards: List-towercard: int-victorypoints: int-color: String(isActive: Boolean)
+getName(): String+setName(): void+getSweets():int+setSweets():void+getRace():String+setRace():void+incrementsSmallFigures():int+decrementsSmallFigures():void+incrementsBigFigures():int+decrementsBigFigures():void+getBuildingCards():int+setBuildingCards():void+getTowerCards():int+setTowerCards():void+getVictorypoints():int+setVictorypoints():void+getColor(): String+setColor(): void+concede():void+buyBuildingcard(): void+buyTowercard(): void+buildaHovel(): void+buildaMansion(): void+deployUndead(): void+retractUndead(): void
ButtonModel
-hasfigure: int-height: int-mansionNr: int
+gethasfigure(): int+sethasfigure(): void+getheight(): int+setheight(): void+getmansionNr(): int+setmansionNr(): void
Buildingcardstack
-hiddenBuildingcardsList:List-visibleBuildingcardsList:List
+gethiddenBuildingcardsList(): List+sethiddenBuildingcardsList(): void+getvisibleBuildingcardsList(): List+setvisibleBuildingcardsList(): void
PlayerView
-buttonList: List
Button
-theModel:ButtonModel
MenueView
BuildingTowerView
GameController
-View:TheView-playersList: List
+startGame(): void+loadGame(): void+saveGame() : void+quitGame() : void+changeLanguage() : void+showInstructions() : void+addPlayer() : void+randomizeboard() : void
Hovel
-hauntValue: int
+gethauntValue(): int+sethauntValue(): void+extendHovel(): void
Map
-grid: GridLayout-buttonList: List
Mansion
-hauntValue: int-color: String
+gethauntValue(): int+sethauntValue(): void+getcolor(): String+setcolor(): void+extendMansion(): void
GameSettingView
CardView
AbstractView
+resize():void
TheView
-viewList:List
+switchView(JPanel view) : void
0 条评论
下一页