list of dots

User Manual    [Previous]   [Next]   

W069 Auto Transition Conflict

Umple semantic warning issued when an auto-transition has a conflict with a previously defined transition

An auto-transition in a state that is declared after another auto-transition will be ignored, and only the first auto-transition will be executed. No warning is issued if the destination state of both auto-transitions is the same.

Example

//The warning is generated due
//to the auto-transition to s2
//conflicting with the auto-
//transition to s3
class A {
  sm {
    s1 {
      entry /{doSomething();}
      -> s2;
      
      do {doSomethingElse();}
      -> s3;
    }
    s2 {
    }
    s3 {
    }
  }
  void doSomething() {}
  void doSomethingElse() {}
}
      

Load the above code into UmpleOnline

 

Solution to The Above So the Message No Longer Appears

//The warning is avoided here
//by keeping only one auto-
//transition
class A {
  sm {
    s1 {
      entry /{doSomething();}
      do {doSomethingElse();}
      -> s2;
    }
    s2 {
    }
  }
  void doSomething() {}
  void doSomethingElse() {}
}
      

Load the above code into UmpleOnline