Communicating structure with class diagrams
Class diagrams are perhaps the most popular part of Unified Modeling Language (UML), which emerged as a standardized way of communicating software designs in the late 1990’s.
A class diagram contains a series of boxes representing software classes and lists the methods and attributes of each class, along with how classes relate to each other.
This makes class diagrams useful in illustrating how a set of classes within your application might interact.
We can see a simple class diagram from a game development project by adding a new Mermaid code cell with the following contents:
classDiagram direction LR GameObject <|-- Character Character *-- Weapon GameObject <|-- Projectile Weapon o-- Projectile
This defines a diagram of the classDiagram
type that goes from left to right and defines relationships...