Beispiel #1
0
 static <POWER extends SuperHearing & SuperSmell> void superFind(SuperHero<POWER> hero) {
   hero.getPower().hearSubtleNoises();
   hero.getPower().trackBySmell();
 }
Beispiel #2
0
 // Bounds in generic methods:
 static <POWER extends SuperHearing> void useSuperHearing(SuperHero<POWER> hero) {
   hero.getPower().hearSubtleNoises();
 }