Skip to content

Instantly share code, notes, and snippets.

@alan80avalos
Created October 4, 2025 03:47
Show Gist options
  • Select an option

  • Save alan80avalos/352e2103f4ae7daab9b1024d8ee185fe to your computer and use it in GitHub Desktop.

Select an option

Save alan80avalos/352e2103f4ae7daab9b1024d8ee185fe to your computer and use it in GitHub Desktop.
@startuml
interface Motor {
+mover()
}
interface Chofer {
+manejar()
}
class MotorCombustion implements Motor {
+mover()
}
class MotorElectrico implements Motor {
+mover()
}
class Robot implements Chofer {
+manejar()
}
class Humano implements Chofer {
+manejar()
}
class Transporte {
-motor: Motor
-chofer: Chofer
+entregar(destino: String, carga: String)
+setMotor(m: Motor)
+setChofer(c: Chofer)
}
MotorCombustion ..|> Motor
MotorElectrico ..|> Motor
Robot ..|> Chofer
Humano ..|> Chofer
Transporte --> Motor
Transporte --> Chofer
@enduml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment