[SPARK-911] allow efficient queries for a range if RDD is partitioned wi...

...th RangePartitioner
I think it would be clearer to define this as a function (`def rangeFilter(iter: Iterator[P])`) rather than as a `val`.