d1a11e955077906d793c5f6ca9eee3c40a77f1b0 braney Wed Feb 19 14:24:48 2020 -0800 use a name index in a bigBed if available and there are identifiers in hgTables and the region is whole genome diff --git src/lib/hash.c src/lib/hash.c index 67dca93..297a994 100644 --- src/lib/hash.c +++ src/lib/hash.c @@ -451,30 +451,43 @@ { next = hel->next; int hashVal = hel->hashVal & hash->mask; hel->next = hash->table[hashVal]; hash->table[hashVal] = hel; } } /* restore original list order */ hashReverseAllBucketLists(hash); if (!hash->lm) freeMem(oldTable); hash->numResizes++; } +struct slName *hashSlNameFromHash(struct hash *hash) +/* Create a slName list from the names in a hash. */ +{ +struct slName *list = NULL; +struct hashCookie cookie = hashFirst(hash); +struct hashEl *hel; +while ((hel = hashNext(&cookie)) != NULL) + { + struct slName *one = newSlName(hel->name); + slAddHead(&list, one); + } +return list; +} struct hash *hashFromSlNameList(void *list) /* Create a hash out of a list of slNames. */ { struct hash *hash = NULL; struct slName *namedList = list, *item; if (!list) return NULL; hash = newHash(0); for (item = namedList; item != NULL; item = item->next) hashAdd(hash, item->name, item); return hash; } struct hash *hashSetFromSlNameList(void *list)