Skip to content

Latest commit

 

History

History
23 lines (23 loc) · 464 Bytes

File metadata and controls

23 lines (23 loc) · 464 Bytes

Class Diagram

---
title: Checkout Domain
---
classDiagram
    direction LR
    class Order {
        +string id
        +Create(items []LineItem) error
        +Pay() error
    }
    class LineItem {
        +string sku
        +int quantity
        +Subtotal() int
    }
    class PaymentGateway
    <<Interface>> PaymentGateway
    Order "1" *-- "many" LineItem : contains
    Order --> PaymentGateway : uses
    note for Order "Aggregate Root"
Loading