Improve ResultSetIterator to correctly follow Iterator specification

next() must throw NoSuchElementException
Automatic close of ResultSetIterator when reaching last element
Simplify the building of sorting criteria of ES requests