client code changed: 0 lines
Business code · never changes
// talks only to the interface repo.findAll() repo.save(user) repo.delete(id)
📚
UserRepository
the only thing
that knows
the backend
In-Memory
Storage backend · swappable
Same API, swappable storage
Click a backend chip on the right, then run + Add user. Watch the caller code stay identical while the storage changes.
The caller never touches the shelves — it just asks the librarian. Only the Repository knows which backend answers.