Indexed Categories And Their Applications