adding index class