Get the Users in the Community.

@param integer $limit Amount of Users to return.
@return array Array of Api\User.
330066
public function members(int $limit = 100) : array
    {
        $returnMembers = [];

        $members = $this->get(sprintf(self::COMMUNITY_ENDPOINT . 'communities/%s/members', $this->id()), [
            'limit' => $limit
        ]);

        if ($members->size === 0) return $returnMembers;

        foreach ($members->members as $member) {
            $returnMembers[] = new User($this->client, $member->onlineId);
        }

        return $returnMembers;
    }
1225283
public function getMemberInfo($limit = null, $offset = 0, $memberRoleFilter = null, $memberInfoFilter = null, $appDefinedDataFilter = null)
    {
        $request = new GetGroupMemberInfoRequest($this->groupId, $limit, $offset, $memberRoleFilter, $memberInfoFilter, $appDefinedDataFilter);
        $response = new GetGroupMemberInfoResponse();
        return $this->client->sendRequest($request, $response);
    }
130578
public function findByStatusIdAndUser($locale, $statusId, UserInterface $user, $limit = null)
    {
        return $this->findByStatusIdsAndUser($locale, [$statusId], $user, $limit);
    }
1105277
public function read($limit = 0)
    {
        $this->limit($limit);
        $query = $this->buildSelect();
        $this->run($query['query'], $query['param']);

        return $this->next();
    }
1347432
public function rangeLimit(int $max, int $limit) : array
        {
                $response =  $this->_redis->zrevrangebyscore($this->_key, $max, '-inf','WITHSCORES', 'LIMIT', 0, $limit);
                $result   = [];
                for($i=0,$num=count($response);$i<$num;$i++) {
                        $result[$response[$i]] = intval($response[++$i]);
                }
                return $result;
        }
134618
public function getUserFeed($limit = 0)
    {
        $params = array();
        if ($limit > 0) {
            $params['count'] = $limit;
        }

        return $this->_makeCall('users/self/feed', true, $params);
    }
216990
public function findLimited($limit = 0)
    {
        $queryBuilder = $this->createQueryBuilder('c')
            ->where('c.enabled = :enabled')
            ->orderBy('c.position')
            ->setParameters(array(
                'enabled' => true,
            ));

        if ($limit != 0) {
            $queryBuilder->setMaxResults($limit);
        }

        return $queryBuilder->getQuery()->getResult();
    }
411759
public function fetchData($userName, $limit)
    {
        /** @var Cache $cache */
        $cache = $this->cacheManager->getCache($userName);

        $variables = [
            'id'    => $cache->getUserId(),
            'first' => $limit,
            'after' => $this->endCursor,
        ];

        $cookieJar = CookieJar::fromArray($cache->getCookie(), 'www.instagram.com');

        $headers = [
            'headers' => [
                'user-agent'       => self::USER_AGENT,
                'x-requested-with' => 'XMLHttpRequest',
                'x-instagram-gis'  => $this->generateGis($cache->getRhxGis(), $variables)
            ],
            'cookies' => $cookieJar
        ];

        $endpoint = self::INSTAGRAM_ENDPOINT . 'graphql/query/?query_hash=' . self::QUERY_HASH . '&variables=' . json_encode($variables);

        $res = $this->client->request('GET', $endpoint, $headers);

        $data = (string)$res->getBody();
        $data = json_decode($data);

        if ($data === null) {
            throw new InstagramException(json_last_error_msg());
        }

        // save to cache for next request
        $newCache = new Cache();
        $newCache->setRhxGis($cache->getRhxGis());
        $newCache->setUserId($cache->getUserId());
        if ($res->hasHeader('Set-Cookie')) {
            $newCache->setCookie($res->getHeaders()['Set-Cookie']);
        }

        $this->cacheManager->set($newCache, $userName);

        return $data->data->user;
    }
1072369
public function GetByUser($UserID, $Limit, $Offset = 0) {
      // Get category permissions
      $Perms = DiscussionModel::CategoryPermissions();
      
      // Build main query
      $this->CommentQuery(TRUE, FALSE);
      $this->FireEvent('BeforeGet');
      $this->SQL
			->Select('d.Name', '', 'DiscussionName')
			->Join('Discussion d', 'c.DiscussionID = d.DiscussionID')
         ->Where('c.InsertUserID', $UserID)
			->OrderBy('c.CommentID', 'desc')
         ->Limit($Limit, $Offset);
      
      // Verify permissions (restricting by category if necessary)
      if($Perms !== TRUE) {
         $this->SQL
            ->Join('Category ca', 'd.CategoryID = ca.CategoryID', 'left')
            ->WhereIn('d.CategoryID', $Perms);
      }
      
      //$this->OrderBy($this->SQL);

      $Data = $this->SQL->Get();
      Gdn::UserModel()->JoinUsers($Data, array('InsertUserID', 'UpdateUserID'));
      
      return $Data;
      
   }
384824
public function getDistrictAdminsAsync($limit = null, $starting_after = null, $ending_before = null)
    {
        return $this->getDistrictAdminsAsyncWithHttpInfo($limit, $starting_after, $ending_before)
            ->then(
                function ($response) {
                    return $response[0];
                }
            );
    }
1226470
public function get_users($userlimit = 0) {
        global $DB;
        $users = $DB->get_records_sql($this->sql, $this->params, 0, $userlimit);
        return $users;
    }
268978
public function getPeople($offset = 0, $limit = 25)
    {
        list($offset, $limit) = $this->normalizeOffsetAndLimit($offset, $limit);

        return $this->request('people', [
            'offset' => $offset,
            'limit' => $limit,
        ]);
    }
23625
public function getUsers()
    {
        // get the user list
        return $this->apiCall('users.list')->then(function (Payload $response) {
            $users = [];
            foreach ($response['members'] as $member) {
                $users[] = new User($this, $member);
            }
            return $users;
        });
    }
644787
protected function getLastSearchesFromSession($limit)
    {
        $lastSearches = $this->session->getLastSearches();
        $lastSearches = array_slice(array_reverse(array_unique($lastSearches)), 0, $limit);

        return $lastSearches;
    }
907525
public function getCustomers($limit = 100, $offset = 0)
    {
        /** @var CustomerFbApi $response */
        $response = $this->call(new Request('customer.get', array(), $limit, $offset), 'DVelopment\FastBill\Model\CustomerFbApi');

        return $response->getResponse()->getCustomers();
    }
311006
public static function get_recent_items(int $limit = 0) {
        global $USER, $PAGE;

        $userid = $USER->id;

        $params = self::validate_parameters(self::get_recent_items_parameters(),
            array(
                'limit' => $limit,
            )
        );

        $limit = $params['limit'];

        self::validate_context(context_user::instance($userid));

        $items = helper::get_recent_items($limit);

        $renderer = $PAGE->get_renderer('core');
        $recentitems = array_map(function($item) use ($renderer) {
            $context = context_module::instance($item->cmid);
            $exporter = new recentlyaccesseditems_item_exporter($item, ['context' => $context]);
            return $exporter->export($renderer);
        }, $items);

        return $recentitems;
    }
892588
public function get_users() : array {
        $users = [];
        foreach ($this->userids as $userid) {
            if ($user = \core_user::get_user($userid)) {
                $users[] = $user;
            }
        }

        return $users;
    }