code: def get_batched(portal_type=None, uid=None, endpoint=None, **kw):
      
  
      # fetch the catalog results
      results = get_search_results(portal_type=portal_type, uid=uid, **kw)
  
      # fetch the batch params from the request
      size = req.get_batch_size()
      start = req.get_batch_start()
  
      # check for existing complete flag
      complete = req.get_complete(default=_marker)
      if complete is _marker:
          # if the uid is given, get the complete information set
          complete = uid and True or False
  
      # return a batched record
      return get_batch(results, size, start, endpoint=endpoint,
                       complete=complete)
docs: Get batched results