# novanzulhilmi/binego architecture

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

- Interactive diagram: https://gitdiagram.com/novanzulhilmi/binego
- Repository: https://github.com/novanzulhilmi/binego

## Overview

This is a small console marketplace for products sold by negotiation or auction. Buyers browse available products, participate in the selected sale, and—if successful—complete a purchase that updates balances, marks the product sold, and records a receipt. Sellers can add negotiation or auction listings, and the app also shows inventory and transaction history. The six Java files form the complete runtime map. Main.java is excerpted only in part, so details of its menu and auction loop are limited to the shown excerpts.

Main entry points: [`Main.java`](https://github.com/novanzulhilmi/binego/blob/main/Main.java) (Menu and sales flow), [`Produk.java`](https://github.com/novanzulhilmi/binego/blob/main/Produk.java) (Product state), [`ProdukNego.java`](https://github.com/novanzulhilmi/binego/blob/main/ProdukNego.java) (Negotiation rules), [`ProdukLelang.java`](https://github.com/novanzulhilmi/binego/blob/main/ProdukLelang.java) (Auction rules)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Console app"]
  node_main["Menu and sales flow<br/>[Main.java]"]
end

subgraph group_sales["Sale models"]
  node_negotiation["Negotiation rules<br/>[ProdukNego.java]"]
  node_auction["Auction rules<br/>[ProdukLelang.java]"]
  node_bidbot["Automated bidder<br/>[BotPenawar.java]"]
end

subgraph group_records["Products and transactions"]
  node_product["Product state<br/>[Produk.java]"]
  node_transaction["Receipt record<br/>[Transaksi.java]"]
end

node_user(("Buyer or seller"))

node_user -->|"uses console"| node_main
node_main -->|"evaluates offers"| node_negotiation
node_main -->|"runs auction"| node_auction
node_main -->|"creates bidders"| node_bidbot
node_main -->|"lists and updates"| node_product
node_main -->|"records purchase"| node_transaction
node_negotiation -->|"extends"| node_product
node_auction -->|"extends"| node_product

click node_main "https://github.com/novanzulhilmi/binego/blob/main/Main.java"
click node_negotiation "https://github.com/novanzulhilmi/binego/blob/main/ProdukNego.java"
click node_auction "https://github.com/novanzulhilmi/binego/blob/main/ProdukLelang.java"
click node_bidbot "https://github.com/novanzulhilmi/binego/blob/main/BotPenawar.java"
click node_product "https://github.com/novanzulhilmi/binego/blob/main/Produk.java"
click node_transaction "https://github.com/novanzulhilmi/binego/blob/main/Transaksi.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_main toneBlue
class node_negotiation,node_auction,node_bidbot toneAmber
class node_product,node_transaction toneMint
class node_user toneIndigo
```

## Components

### Console app

- [Menu and sales flow](https://github.com/novanzulhilmi/binego/blob/main/Main.java): `Main.java`

### Sale models

- [Negotiation rules](https://github.com/novanzulhilmi/binego/blob/main/ProdukNego.java): `ProdukNego.java`
- [Auction rules](https://github.com/novanzulhilmi/binego/blob/main/ProdukLelang.java): `ProdukLelang.java`
- [Automated bidder](https://github.com/novanzulhilmi/binego/blob/main/BotPenawar.java): `BotPenawar.java`

### Products and transactions

- [Product state](https://github.com/novanzulhilmi/binego/blob/main/Produk.java): `Produk.java`
- [Receipt record](https://github.com/novanzulhilmi/binego/blob/main/Transaksi.java): `Transaksi.java`

### Other components

- **Buyer or seller**

## Connections

- Buyer or seller → Menu and sales flow: uses console (evidence: `Main.java`)
- Menu and sales flow → Negotiation rules: evaluates offers (evidence: `Main.java`)
- Menu and sales flow → Auction rules: runs auction (evidence: `Main.java`)
- Menu and sales flow → Automated bidder: creates bidders (evidence: `Main.java`)
- Menu and sales flow → Product state: lists and updates (evidence: `Main.java`)
- Menu and sales flow → Receipt record: records purchase (evidence: `Main.java`)
- Negotiation rules → Product state: extends (evidence: `ProdukNego.java`)
- Auction rules → Product state: extends (evidence: `ProdukLelang.java`)
