Bounded and un-bounded wildcards in Generics are two types of wildcard available on Java. Any Type can be bounded either upper or lower of class hierarchy in Generics by using bounded wildcards. In short <? extends T> and <? super T> represent bounded wildcards while <?> represent an unbounded wildcard in generics . In our last article How Generics works in Java , we have seen some basic details about bounded and unbounded wildcards in generics and In this Java tutorial we will see bounded and unbounded generics wildcards in details. We will start from basics like what is bounded wild card in generics and what is unbounded wildcard and than will some popular java interview questions on generics like Difference between ArrayList<? extends T> and ArrayList<T super ?>.
Kamis, 05 April 2012
core java
What is bounded and unbounded wildcards in Generics Java
Read more »
0 Response to "What is bounded and unbounded wildcards in Generics Java"
Posting Komentar