Added toString method to Index.