Answer Posted / tarun
Please go through this link for more knowledge
http://java.sun.com/j2se/1.5/pdf/generics-tutorial.pdf
Generics is the new feture added in the JAVA5.0. It feature
is useful in some broad applications when we are writing any
database insertion logic for the same type of Object.
suppose we have to insert a list of Employee Object this
will be declared as List<Employee> or suppose we have a list
of long values then we can simply type cast it as
List<Long>, Similarly List<String>, List<Integer>. The
generics class are used by Wrapper classes or any other
classes. Most useful in ORM technologies also.
Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
Is hashset ordered?
What are the states of thread in java?
Why parameters should be passed by reference?
What is the benefit of abstract class?
What is a flag variable?
What are the 7 types of characters?
Why do we declare a class static?
How many bytes is a string java?
What are the methods available in a class?
how to write a program for sending mails between client and server
Can we have two main methods in a java class?
How is abstraction implemented in java ?
What are the four pillars of java?
Explain the use of volatile field modifier?
How do you achieve polymorphism in java?