RepeatRange into a factory