Added an index generator for url/file path mapping
Implemented URI look up based on index register
Changed functions order