java - How could my List lose its order? -
for java application, make pl/sql database query fills out list object in particular order. when run query in pl/sql, list in correct order, , when check results of filling out list, shows list correctly organized.
however, when data appears on our app, , supposed in same order, 2 items on list in incorrect order.
in example testing, there 6 items in list, , 2 being ordered in middle. none of other items on list lose place.
having examined code throughly, have determined exact moment order of list lost when added collection object. relevant processes shown below
what might happening list object in transit collection make lose order?
code example:
collection results = null; results = new treeset(new transactioncomparator(rd.getdescendingorder())); collection c = cleanclass.getlist(); // creates list of ordered items results.addall(c);
Comments
Post a Comment