public void addPossiblesFailuresComplex ( ) { Set < Scenario > scenarios = this . getScenarios ( ) ; for ( Scenario s : scenarios ) { for ( Class < ? extends Failure > c : s . getPossibleFailures ( ) . keySet ( ) ) { if ( ! this . getPossibleFailures ( ) . containsKey ( c ) ) { this . addPossibleFailure ( c , s . getPossibleFailures ( ) . get ( c ) ) ; } else { List < Set < NetworkElement >> elements = this . getPossibleFailures ( ) . get ( c ) ; // elements.addAll(s.getPossibleFailures().get(c)); for ( Set < NetworkElement > sne : s . getPossibleFailures ( ) . get ( c ) ) { if ( ! elements . contains ( sne ) ) elements . add ( sne ) ; } this . addPossibleFailure ( c , elements ) ; } } } }
Idem que con los eventos y los dupes