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
Can we pass null as argument in java?
Can a variable be local and static at the same time?
What are the differences between Java 1.0 and Java 2.0?
Explain polymorphism citing an example.
How do you calculate roots in java?
What is an array length?
How to convert string to byte array and vice versa?
Why string is a class?
what state does a thread enter when it terminates its processing? : Java thread
What is meant by interface?
Can you extend singleton class?
What is the difference between a local variable and an instance variable?
What java ide should I use?
What is a pointer and does java support pointers?
What things should be kept in mind while creating your own exceptions in java?