25 lines
485 B
Java
Executable File
25 lines
485 B
Java
Executable File
/* Subtype Vector<Pair<a,b>> OK */
|
|
|
|
/* Subtype Vector<? extends Pair<a,b>> */
|
|
|
|
/* Korrekt */
|
|
|
|
/* Vector<Subtype<Integer>> Vector<? extends Vector<? extends Pair<a,b>>> */
|
|
|
|
/* Super, FUNKTIONIERT!!! */
|
|
|
|
/* Vector<List<? super Integer>> Vector<? super Vector<a>> */
|
|
|
|
/* redureSup Test: FUNKTIONIERT!!! */
|
|
|
|
class Number {}
|
|
class Integer extends Number {}
|
|
|
|
class List<a> { }
|
|
|
|
class Vector<a> extends List<a> { }
|
|
|
|
class Pair<a,b> { }
|
|
|
|
|
|
class Subtype<a> extends Vector<Pair<a,Integer>> { } |