extract method to indexutils