Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Collections

 
Padma Priya
Ranch Hand
Posts: 123
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Everybody

What does the letter E in Interface Collection<E>mean..And also what does the letter T in Comparator<T> mean.Like wise what do K,V mean in Map<K,V>.Do they have any special meaning or reference.

Thanks in advance
with regards
Deepthi
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24204
34
Chrome Eclipse IDE Mac OS X
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do you understand about generics, and are just asking if the letters themselves mean anything, or do you not know what the whole angle-bracket notation is about in the first place?

If it's the former, I'd guess that E is for element, K and V are for key and [/i]value, and T is for type. But they're arbitrary -- could be any letter.

If you don't know what the angle brackets mean, they are part of something new in Java 5 called generics. http://java.sun.com/j2se/1.5.0/docs/guide/language/generics.html is one place you might start to learn about this.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic