-
Notifications
You must be signed in to change notification settings - Fork 0
System Design
Guilherme Miranda edited this page Jul 12, 2025
·
2 revisions
The project is structured in a layered architecture to separate user interface, chess logic, and board logic.
- UI Layer: Handles input/output and game flow (application/Program.java)
- Chess Layer: Implements chess rules, moves, and validation (chess package)
- Board Layer: Manages board, pieces, positions, and exceptions (boardgame package)
- Classes and Objects
- Encapsulation
- Inheritance
- Polymorphism
- Abstraction (abstract classes, methods)
- Custom exception handling
-
Position: Board coordinates (row, column) -
Board: Board logic, pieces, and rules -
Piece: Generic chess piece superclass -
BoardException: For invalid board operations
-
ChessMatch: Controls game logic and flow -
ChessPiece: Extends Piece for chess-specific logic -
ChessPosition: Converts chess notation (e.g., e4) to matrix positions -
ChessException: Handles chess-specific errors
- King (incl. castling)
- Queen
- Rook
- Bishop
- Knight
- Pawn (incl. promotion, en passant)