This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes Using generics while creating objects Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Using generics while creating objects" Watch "Using generics while creating objects" New topic

Using generics while creating objects

srujana maredugu

Joined: Jan 10, 2008
Posts: 8
What is the difference between creating object using Generics in java 1.5.

List<String> l=new ArrayList(); and
List l=new ArrayList<String>();
[ February 06, 2008: Message edited by: Jaikiran Pai ]
Jaikiran Pai

Joined: Jul 20, 2005
Posts: 10441


Welcome to JavaRanch

While posting a question please use a meaningful subject line. Doing so, you are more likely to get answers to your questions. I modified the subject line to be meaningful. I'll move this question to our JiG(B) forum where this is more appropriate.
[ February 06, 2008: Message edited by: Jaikiran Pai ]

[My Blog] [JavaRanch Journal]
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link:
subject: Using generics while creating objects
It's not a secret anymore!