I'm not sure how to model sub-methods in UML sequence diagram. When in the execution of one method another method is called (from the same class). I tried to give an example below:
How would you guys model this in UML (in a sequence diagram)?
..
car1.drive();
..
... in Car class:
..
drive(){
this.startEngine();
}
startEngine(){
this.getKey();
this.insertKey();
}
..
a small begin:
objx car1
---- ----
| |
| drive() |
|-------->| startEngine()
| |------------.
| | |
| |<-----------.
| |
But where comes the getKey() method? Must this be communicated via another sequence diagram? Or is there a way to include sub procedures?