# bearatron/team-project architecture

> Architecture diagram of the GitHub repository bearatron/team-project, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-21). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/bearatron/team-project
- Repository: https://github.com/bearatron/team-project

## Overview

This is a planned campus food-truck discovery and review application; the README describes the intended user workflows, but the checked-in runtime is currently an entity-focused scaffold. The map, authentication, reviews, owner tools, and API integrations are documented capabilities, not sampled implementations. The graph separates those planned stages from the domain objects that do exist; dashed links mark documented external integrations whose code is not present in the excerpts.

Main entry points: [`src/main/java/use_case`](https://github.com/bearatron/team-project/tree/main/src/main/java/use_case) (Use cases), [`src/main/java/entities/FoodTruck.java`](https://github.com/bearatron/team-project/blob/main/src/main/java/entities/FoodTruck.java) (Food truck), [`src/main/java/app/package-info.java`](https://github.com/bearatron/team-project/blob/main/src/main/java/app/package-info.java) (Application setup), [`src/main/java/view`](https://github.com/bearatron/team-project/tree/main/src/main/java/view) (Views)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_experience["User experience"]
  node_ui["Views"]
  node_auth["Account access"]
  node_map["Truck map"]
  node_truckdetails["Truck details"]
  node_reviews["Reviews and replies"]
  node_owner["Owner management"]
  node_summary["Review summaries"]
end

subgraph group_application["Application flow"]
  node_app["Application setup<br/>[package-info.java]"]
  node_adapters["Interface adapters<br/>[package-info.java]"]
  node_usecases["Use cases"]
  node_dataaccess["Data access<br/>[package-info.java]"]
end

subgraph group_domain["Domain model"]
  node_foodtruck["Food truck<br/>[FoodTruck.java]"]
  node_menuitem["Menu item<br/>[MenuItem.java]"]
  node_pricerange["Price range<br/>[PriceRange.java]"]
  node_location["Location<br/>[Location.java]"]
  node_review["Review<br/>[Review.java]"]
  node_rating["Rating<br/>[Rating.java]"]
  node_userentity["Account and role<br/>[User.java]"]
  node_usertype["Account role<br/>[UserType.java]"]
end

subgraph group_integrations["External services"]
  node_customapi{{"Location API"}}
  node_googlemaps{{"Google Maps API"}}
  node_gemini{{"Gemini API"}}
end

node_user(("User"))

node_user -->|"uses"| node_ui
node_ui -.->|"submits requests"| node_adapters
node_adapters -->|"translates requests"| node_usecases
node_app -->|"builds views"| node_ui
node_app -->|"wires use cases"| node_usecases
node_app -->|"wires data access"| node_dataaccess
node_usecases -->|"handles sign-in"| node_auth
node_usecases -->|"gets truck locations"| node_map
node_usecases -->|"loads details"| node_truckdetails
node_usecases -->|"handles review actions"| node_reviews
node_usecases -->|"handles truck updates"| node_owner
node_usecases -->|"requests summaries"| node_summary
node_map -.->|"fetches locations"| node_customapi
node_reviews -.->|"imports reviews"| node_googlemaps
node_summary -.->|"generates summary"| node_gemini
node_foodtruck -->|"stores menu"| node_menuitem
node_foodtruck -->|"stores reviews"| node_review
node_foodtruck -->|"has location"| node_location
node_foodtruck -->|"calculates range"| node_pricerange
node_userentity -->|"has role"| node_usertype
node_reviews -.->|"creates and displays"| node_review
node_truckdetails -.->|"displays truck"| node_foodtruck
node_owner -.->|"updates truck"| node_foodtruck
node_summary -.->|"summarizes reviews"| node_review

click node_app "https://github.com/bearatron/team-project/blob/main/src/main/java/app/package-info.java"
click node_ui "https://github.com/bearatron/team-project/tree/main/src/main/java/view"
click node_adapters "https://github.com/bearatron/team-project/blob/main/src/main/java/interface_adapter/package-info.java"
click node_usecases "https://github.com/bearatron/team-project/tree/main/src/main/java/use_case"
click node_auth "https://github.com/bearatron/team-project/tree/main/src/main/java/use_case"
click node_map "https://github.com/bearatron/team-project/tree/main/src/main/java/use_case"
click node_truckdetails "https://github.com/bearatron/team-project/tree/main/src/main/java/use_case"
click node_reviews "https://github.com/bearatron/team-project/tree/main/src/main/java/use_case"
click node_owner "https://github.com/bearatron/team-project/tree/main/src/main/java/use_case"
click node_summary "https://github.com/bearatron/team-project/tree/main/src/main/java/use_case"
click node_foodtruck "https://github.com/bearatron/team-project/blob/main/src/main/java/entities/FoodTruck.java"
click node_menuitem "https://github.com/bearatron/team-project/blob/main/src/main/java/entities/MenuItem.java"
click node_pricerange "https://github.com/bearatron/team-project/blob/main/src/main/java/entities/PriceRange.java"
click node_location "https://github.com/bearatron/team-project/blob/main/src/main/java/entities/Location.java"
click node_review "https://github.com/bearatron/team-project/blob/main/src/main/java/entities/Review.java"
click node_rating "https://github.com/bearatron/team-project/blob/main/src/main/java/entities/Rating.java"
click node_userentity "https://github.com/bearatron/team-project/blob/main/src/main/java/entities/User.java"
click node_usertype "https://github.com/bearatron/team-project/blob/main/src/main/java/entities/UserType.java"
click node_dataaccess "https://github.com/bearatron/team-project/blob/main/src/main/java/data_access/package-info.java"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_ui,node_auth,node_map,node_truckdetails,node_reviews,node_owner,node_summary,node_user toneBlue
class node_app,node_adapters,node_usecases,node_dataaccess toneAmber
class node_foodtruck,node_menuitem,node_pricerange,node_location,node_review,node_rating,node_userentity,node_usertype toneMint
class node_customapi,node_googlemaps,node_gemini toneRose
```

## Components

### User experience

- [Views](https://github.com/bearatron/team-project/tree/main/src/main/java/view): `src/main/java/view`
- [Account access](https://github.com/bearatron/team-project/tree/main/src/main/java/use_case): `src/main/java/use_case`
- [Truck map](https://github.com/bearatron/team-project/tree/main/src/main/java/use_case): `src/main/java/use_case`
- [Truck details](https://github.com/bearatron/team-project/tree/main/src/main/java/use_case): `src/main/java/use_case`
- [Reviews and replies](https://github.com/bearatron/team-project/tree/main/src/main/java/use_case): `src/main/java/use_case`
- [Owner management](https://github.com/bearatron/team-project/tree/main/src/main/java/use_case): `src/main/java/use_case`
- [Review summaries](https://github.com/bearatron/team-project/tree/main/src/main/java/use_case): `src/main/java/use_case`

### Application flow

- [Application setup](https://github.com/bearatron/team-project/blob/main/src/main/java/app/package-info.java): `src/main/java/app/package-info.java`
- [Interface adapters](https://github.com/bearatron/team-project/blob/main/src/main/java/interface_adapter/package-info.java): `src/main/java/interface_adapter/package-info.java`
- [Use cases](https://github.com/bearatron/team-project/tree/main/src/main/java/use_case): `src/main/java/use_case`
- [Data access](https://github.com/bearatron/team-project/blob/main/src/main/java/data_access/package-info.java): `src/main/java/data_access/package-info.java`

### Domain model

- [Food truck](https://github.com/bearatron/team-project/blob/main/src/main/java/entities/FoodTruck.java): `src/main/java/entities/FoodTruck.java`
- [Menu item](https://github.com/bearatron/team-project/blob/main/src/main/java/entities/MenuItem.java): `src/main/java/entities/MenuItem.java`
- [Price range](https://github.com/bearatron/team-project/blob/main/src/main/java/entities/PriceRange.java): `src/main/java/entities/PriceRange.java`
- [Location](https://github.com/bearatron/team-project/blob/main/src/main/java/entities/Location.java): `src/main/java/entities/Location.java`
- [Review](https://github.com/bearatron/team-project/blob/main/src/main/java/entities/Review.java): `src/main/java/entities/Review.java`
- [Rating](https://github.com/bearatron/team-project/blob/main/src/main/java/entities/Rating.java): `src/main/java/entities/Rating.java`
- [Account and role](https://github.com/bearatron/team-project/blob/main/src/main/java/entities/User.java): `src/main/java/entities/User.java`
- [Account role](https://github.com/bearatron/team-project/blob/main/src/main/java/entities/UserType.java): `src/main/java/entities/UserType.java`

### External services

- **Location API**
- **Google Maps API**
- **Gemini API**

### Other components

- **User**

## Connections

- User → Views: uses (evidence: `README.md`)
- Views → Interface adapters: submits requests
- Interface adapters → Use cases: translates requests (evidence: `src/main/java/interface_adapter/package-info.java`)
- Application setup → Views: builds views (evidence: `src/main/java/app/package-info.java`)
- Application setup → Use cases: wires use cases (evidence: `src/main/java/app/package-info.java`)
- Application setup → Data access: wires data access (evidence: `src/main/java/app/package-info.java`)
- Use cases → Account access: handles sign-in (evidence: `README.md`)
- Use cases → Truck map: gets truck locations (evidence: `README.md`)
- Use cases → Truck details: loads details (evidence: `README.md`)
- Use cases → Reviews and replies: handles review actions (evidence: `README.md`)
- Use cases → Owner management: handles truck updates (evidence: `README.md`)
- Use cases → Review summaries: requests summaries (evidence: `README.md`)
- Truck map → Location API: fetches locations (evidence: `README.md`)
- Reviews and replies → Google Maps API: imports reviews (evidence: `README.md`)
- Review summaries → Gemini API: generates summary (evidence: `README.md`)
- Food truck → Menu item: stores menu (evidence: `src/main/java/entities/FoodTruck.java`)
- Food truck → Review: stores reviews (evidence: `src/main/java/entities/FoodTruck.java`)
- Food truck → Location: has location (evidence: `src/main/java/entities/FoodTruck.java`)
- Food truck → Price range: calculates range (evidence: `src/main/java/entities/FoodTruck.java`)
- Account and role → Account role: has role (evidence: `src/main/java/entities/User.java`)
- Reviews and replies → Review: creates and displays
- Truck details → Food truck: displays truck
- Owner management → Food truck: updates truck
- Review summaries → Review: summarizes reviews
