add factory class
refacotor indexer to use factory
refactor input provider to user factory
refactor input reader to use factory
indexer signature update