This week's giveaway is in the EJB and other Java EE Technologies forum.
We're giving away four copies of EJB 3 in Action and have Debu Panda, Reza Rahman, Ryan Cuprak, and Michael Remijan on-line!
See this thread for details.
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Generics Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Generics" Watch "Generics" New topic
Author

Generics

Meena R. Krishnan
Ranch Hand

Joined: Aug 13, 2006
Posts: 178
Source JMMock


question is, at line 1, the type parameter <T> is given but not being used and the compiler is not complaining. Is such a syntax ok?
Barry Gaunt
Ranch Hand

Joined: Aug 03, 2002
Posts: 7729
It's clearly redundant to have <T> there and not being used. Syntax-wise it is OK, so the compiler need not complain.


Ask a Meaningful Question and HowToAskQuestionsOnJavaRanch
Getting someone to think and try something out is much more useful than just telling them the answer.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Generics
 
Similar Threads
Another Java Inquisition Quesion
Generics question
Generic Method declaration
K & B Mock exam Generics doubt
Generics: mock exam question