For #3 and #4 partial implementation
For #3 and #4 got getResourceSet working with count options both segment and inline