Extracted 'cache list management' out into new class, Index. This enables us to use the cache from several places (instead of it being private to collision detection).