@param int $offset
@param int $limit
@param array $options
@return mixed

@throws StreamFeedException
354515
public function getActivities($offset = 0, $limit = 20, $options = [], $enrich=false, $reactions = null)
    {
        if($options === null){
            $options = [];
        }
        $query_params = ['offset' => $offset, 'limit' => $limit];
        if (array_key_exists('mark_read', $options) && is_array($options['mark_read'])) {
            $options['mark_read'] = implode(',', $options['mark_read']);
        }
        if (array_key_exists('mark_seen', $options) && is_array($options['mark_seen'])) {
            $options['mark_seen'] = implode(',', $options['mark_seen']);
        }
        $query_params = array_merge($query_params, $options);

        if($reactions !== null){
            if(!is_array($reactions)){
                throw new StreamFeedException("reactions argument should be an associative array");
            }
            if(isset($reactions["own"]) && $reactions["own"]){
                $query_params["withOwnReactions"] = true;
                $enrich = true;
            }
            if(isset($reactions["recent"]) && $reactions["recent"]){
                $query_params["withRecentReactions"] = true;
                $enrich = true;
            }
            if(isset($reactions["counts"]) && $reactions["counts"]){
                $query_params["withReactionCounts"] = true;
                $enrich = true;
            }
        }

        $prefix_enrich = $enrich ? 'enrich/' : '';

        return $this->makeHttpRequest("{$prefix_enrich}{$this->base_feed_url}/", 'GET', null, $query_params, 'feed', 'read');
    }
849795
public function get($code, $offset = 0, $limit = self::MAX_GET_USERS): array
    {
        $options = ['json' => [
            'code' => $code,
            'offset' => $offset,
            'size' => $limit
        ]];

        /** @var JsonStream $stream */
        $stream = $this->client
            ->get(UserApi::generateUrl('organization/users.json'), $options)
            ->getBody();

        return $stream->jsonSerialize()['userTitles'];
    }
1086376
public function limit($limit, $offset = 0)
    {
        return $this->alterDataQuery(function (DataQuery $query) use ($limit, $offset) {
            $query->limit($limit, $offset);
        });
    }
631416
final public function limit($limit,$offset=null) {
      if (is_numeric($limit) || is_array($limit)) {
         if(is_array($limit)) {
            $temp   = $limit;
            $limit  =  $temp[0];
            $offset = @$temp[1];
         }

         $this->limit = " LIMIT {$limit} ";

         if(is_numeric($offset)) {
            $this->offset( $offset );
         }
         $this->find_first_data = $this->find_save_data = $this->find_delete_data = FALSE;

         $this->get_instance();
         return $this;
      }

      return null;
   }
316247
public function formatLimitOffset($limit, $offset = 0) {
        if ($limit && $offset) {
            return sprintf($this->getClause(self::LIMIT_OFFSET), (int) $limit, (int) $offset);
        }

        return $this->formatLimit($limit);
    }
205616
public function limit($limit, $offset = 0)
    {
        $this->limit = $limit;
        $this->offset = $offset;

        return $this;
    }
88542
final public function limit($limit, $offset = 0)
    {
        $this->_sql['limit'] = $limit;
        $this->offset($offset);
        return $this;
    }
144466
public function limit($limit, $offset = NULL)
	{
		$this->emptyResult();

		$this->queryBuilder->limit($limit, $offset);
		return $this;
	}
1147407
public function loadAllLocations($offset, $limit)
    {
        $rows = $this->locationGateway->loadAllLocationsData($offset, $limit);

        return $this->locationMapper->createLocationsFromRows($rows);
    }
791159
public function limit($limit = null, $offset = null)
    {
        $this->results = $this->fetch($limit, $offset);

        return $this->results->fetchAll();
    }
524113
public function read(
        int $offset = ClientInterface::DEFAULT_OFFSET,
        int $limit = ClientInterface::DEFAULT_LIMIT
    ): array {
        return $this->doRead($this->file, $this->sheet, $this->range, $offset, $limit);
    }
630641
private function runQuery(Collection $collection, int $offset, int $limit): Iterator
    {
        $collectionQuery = $collection->getQuery();
        if (!$collectionQuery instanceof Query) {
            return new ArrayIterator();
        }

        $queryOffset = $offset - $this->getManualItemsCount($collection, 0, $offset);
        $queryLimit = $limit - $this->getManualItemsCount($collection, $offset, $offset + $limit);

        return $this->queryRunner->runQuery($collectionQuery, $queryOffset, $queryLimit);
    }
211207
private function fromCache($offset, $limit)
    {
        $items = array();

        for ($i = $offset; $i < ($offset + $limit); $i++) {
            if (!array_key_exists($i, $this->cached)) {
                break;
            }

            $items[] = $this->cached[$i];
        }

        return $items;
    }
992767
public function loadUrlWildcardsData($offset = 0, $limit = -1)
    {
        $limit = $limit === -1 ? self::MAX_LIMIT : $limit;

        /** @var $query \eZ\Publish\Core\Persistence\Database\SelectQuery */
        $query = $this->dbHandler->createSelectQuery();
        $query->select(
            '*'
        )->from(
            $this->dbHandler->quoteTable('ezurlwildcard')
        )->limit(
            $limit > 0 ? $limit : self::MAX_LIMIT,
            $offset
        );

        $stmt = $query->prepare();
        $stmt->execute();

        return $stmt->fetchAll(\PDO::FETCH_ASSOC);
    }
1288893
public function getItems($offset, $limit) {
		$this->select->limit($limit, $offset);
		
		return $this->datagate->fetchAll($this->select);
	}
774904
protected function switchPersisterContext($offset, $limit)
    {
        if (null === $offset && null === $limit) {
            $this->currentPersisterContext = $this->noLimitsContext;

            return;
        }

        $this->currentPersisterContext = $this->limitsHandlingContext;
    }
170338
public function read( $offset = NULL, $limit = NULL )
	{
		return $this->load( $this->fileName, $offset, $limit );
	}