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 string is a data type?
What is the size of int in 64-bit jvm?
Can anonymous class have constructor?
Given a singly linked list, find the middle of the list in a single traversal without using temporary variable.
What is the purpose of declaring a variable as final?
What is purpose of find feature?
there are N number of matchboxes numbered 1...N.each matchbox contain various number of stick.Two player can alternatevely pick some amount of stick from the higest stick containing box . The player is condidered win if there is no stick after his move.Find the final move so that the move player win. Note:In case the number of stick is equal ,pick the stick from the higest numbered box.
What do you understand by soft reference?
Explain the difference between transient and volatile in java?
how to create multithreaded program? Explain different ways of using thread? When a thread is created and started, what is its initial state? : Java thread
What is meant by stack and queue?
What is immutable in java?
What is cr keyboard?
Can vector have duplicates in java?
What happens if an exception is not handled in a program?