This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes The Diamond Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "The Diamond" Watch "The Diamond" New topic

The Diamond

meeta gaur
Ranch Hand

Joined: Dec 05, 2012
Posts: 305 error: incompatible types
Pair<String,Colour<String>> obj3=new OrderedPair<>("k3",new Colour<>());
required: Pair<String,Colour<String>>
found: OrderedPair<String,Colour<Object>>
1 error

Why diamond isn't working for Colour?

My one regret in life is that I am not someone else.
- Woody Allen
I agree. Here's the link:
subject: The Diamond
Similar Threads
Inner classes & Static blocks
inner class/inheritance
Inheriting variable and static functions
question concering hashCode(), equals() and operator ==