allow passing IO object
handle Range with Time