getServiceLocator()->get(SearchProxy::SERVICE_ID); $query = new SearchQuery( $searchString, TaoOntology::CLASS_URI_TAO_USER, TaoOntology::CLASS_URI_TAO_USER, 0, 10, 1 ); $result = $searchProxy->searchByQuery($query); return $this->getUsers(array_column($result['data'] ?? [], 'id')); } /** * {@inheritDoc} * @see \oat\oatbox\user\UserService::getUser() */ public function getUser($userId) { return new \core_kernel_users_GenerisUser($this->getResource($userId)); } /** * {@inheritDoc} * @see \oat\oatbox\user\UserService::getUsers() */ public function getUsers($userIds) { $users = []; foreach ($userIds as $id) { $users[$id] = $this->getUser($id); } return $users; } }