self
end
+ def distinct(bool=true)
+ @distinct = bool
+ self
+ end
+
def limit(max_results)
if not max_results.nil? and not max_results.is_a? Integer
raise ArgumentError("argument to limit() must be an Integer or nil")
api_params[:select] = @select if @select
api_params[:order] = @orderby_spec if @orderby_spec
api_params[:filters] = @filters if @filters
-
+ api_params[:distinct] = @distinct if @distinct
+ if @fetch_multiple_pages
+ # Default limit to (effectively) api server's MAX_LIMIT
+ api_params[:limit] = 2**(0.size*8 - 1) - 1
+ end
item_count = 0
offset = @offset || 0