Performed some re-factoring and also started to add functionality for standard search.