lineSet.add(new DeliveryHouseDetails(line)); This is line 20 that the stacktrace refers to. The problem is that lineSet is a TreeSet and it is grumbling because the thing you are trying to add to it (a new DeliveryHouseDetails) does not implement Comparable. Edited by: pbrockway2 on Apr 7, 2008 2:40 PM In general a Set does not worry about whether its contents are ...