diff --git a/docs/analysis/crc-cards.md b/docs/analysis/crc-cards.md new file mode 100644 index 0000000..0ea3791 --- /dev/null +++ b/docs/analysis/crc-cards.md @@ -0,0 +1,60 @@ +## Conversation + +**Responsibilities** +- Holds and receives messages sent by participants +- Maintains relationships between messages, their replies, and attachments +- Coordinates with read status tracking to determine which message each user last read. + +**Collaborators** +- User +- Message +- WebSocket + + +## WebSocket + +**Responsibilities** +- Updates users in real time when a message, letter, invite, etc. shows up. +- Handles real-time chat events such as typing indicators and read status updates. + +**Collaborators** +- User +- Conversation +- Notification (Inbox) + + +## Message + +**Responsibilities** +- Holds text info on the current message +- Keeps track of who sent the message and the date when it was sent + +**Collaborators** +- Conversation +- User + + +## Notification (Inbox) + +**Responsibilities** +- Contains information about what's in the message +- Tracks who sent it and when +- Holds any associated package content or additional data + +**Collaborators** +- User +- Conversation +- Friend + + +## Friend + +**Responsibilities** +- Represents a friendship relationship between users +- Stores friendship status and metadata (for example, when the friendship was created) +- Supports friend-related actions such as sending and responding to friend requests + +**Collaborators** +- User +- Notification (Inbox) +- Conversation \ No newline at end of file diff --git a/docs/analysis/features-and-usecases.md b/docs/analysis/features-and-usecases.md new file mode 100644 index 0000000..f56766f --- /dev/null +++ b/docs/analysis/features-and-usecases.md @@ -0,0 +1,71 @@ +# Features and Use Cases + +## Features +- Register +- Maintain WS connections +- Online Activities +- Inbox Messages +- Game Library +- Search +- Friends +- Achievement system +- Toast Notifications + +... + +## Brief Use Cases + +### UC1: User creates an account +- Primary Actor: New user +- Goal: User successfully creates and registers his account. + +### UC2: User plays a game +- Primary Actor: User +- Goal: User opens an available game and plays. + +### UC3: User plays online +- Primary Actor: Registered User +- Goal: User connects to online services and plays online game. + +### UC4: System sends an inbox letter to user +- Primary Actor: System +- Goal: System sends a letter to the user's inbox + +### UC5: System alerts user of achievement +- Primary Actor: System +- Goal: System alerts user when he has completed an achievement. + +### UC6: User views the Game Library +- Primary Actor: User +- Goal: User receives the site's library of games + +### UC7: User searches for a specific game, genre, etc. +- Primary Actor: User +- Goal: User receives the results of his search + +### UC8: User becomes friends with another user +- Primary Actor: Registered User +- Goal: The registered user becomes friends with another user and can chat and play online together. + + + +... + +## Use Case Traceability + +| Use Case | Feature(s) | +|---|---| +| UC1: User creates an account | Register | +| UC2: User plays a game | Game Library, WS connections | +| UC3: User plays online | Register, Online Activities, Game Library, WS connections | +| UC4: System sends an inbox letter to user | Register, Inbox Messages | +| UC5: System alerts user of achievement | Register, Achievement system, Toast Notifications | +| UC6: User views the Game Library | Game Library | +| UC7: User searches for a specific game, genre, etc. | Game Library, Search | +| UC8: User becomes friends with another user | Register, Online Activities, Friends | +... + +## Use Case Diagram +Here is my diagram built with PlantUML (AI assisted, so it might not look the greatest) + +![Use Case Diagram](use-case-diagram.png) diff --git a/docs/analysis/use-case-diagram.png b/docs/analysis/use-case-diagram.png new file mode 100644 index 0000000..4e4cf21 Binary files /dev/null and b/docs/analysis/use-case-diagram.png differ