updated readme
bugfix in rebuild indexes
added a method for private usage to get keys and values for a class
some more spec
added more test cases
minor change to flush before rebuild (will be implemented with tests)