[Squirrel-sql-develop] Update Feature Patch: hierachical table display ..
A Java SQL client for any JDBC compliant database
Brought to you by:
colbell,
gerdwagner
From: Henner Z. <HZ...@me...> - 2002-02-18 09:59:15
|
Hi, In the former patch to this topic I replaced the ArrayList to store the table infos with a HashSet - this was because its O(n) to remove from an ArrayList but only O(1) from an HashSet. Unfortunatly, this destroys the order of the tables, sine the hash function has no order .. .. so now I implemented this with a TreeSet that orders the tables alphabetically (for this, I made the IDatabaseObjectInfo extend Comparable and compare the qualified names in DatabaseObjectInfo). This has the nice side-effect, that table names are always sorted, even if JDBC-drivers fail so return them sorted. See attached patch. This is a patch agains current CVS. ciao, -hen |