This week's book giveaway is in the Java 8 forum.
We're giving away four copies of Java 8 in Action and have Raoul-Gabriel Urma, Mario Fusco, and Alan Mycroft on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes Generic Java, Type not bounded Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Beginning Java
Reply locked New topic
Author

Generic Java, Type not bounded

Timothy Leong
Ranch Hand

Joined: May 25, 2005
Posts: 55
Dear guys,
I have declared LinkedList<Customer> LL = new LinkList<Customer> (); in my main class.

Under my class Customer, I have a compareTo method too.

I get an error on Type parameter customer is not within its bound.

I believe the problem lies with the bold portion of the code which sorts the node.

Can somebody guide me please? Thank in advance.

Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17249
    
    6

Duplicate thread. Check in the Java In General (Intermediate)

Mark


Perfect World Programming, LLC - Two Laptop Bag - Tube Organizer
How to Ask Questions the Smart Way FAQ
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Generic Java, Type not bounded
 
Similar Threads
insertion of data
Generic Java
Linked List Sorting Problem
Object Comparable
Generic Java - Linked List