Refactor. Changed readIndexTable from having mutable state to yielding an
iterator
Refactor. Changed from mutable state in readIndexEntries to yielding
Iterators and returning a Vector instead of ArrayBuffer
Refactor. Extracted the definitions section in the for expression to an
own method
Case class does not need explicit val for fields
Refactor. Avoid use of return. Changed if return to if-else
Keep hash as String instead