Get all the system users.

@return Entity\Users[]|false
512574
public function getUsers()
    {
        $userEntities = $this->findAll();
        if ($userEntities) {
            foreach ($userEntities as $userEntity) {
                $this->unsetSensitiveFields($userEntity);
            }
        }

        return $userEntities;
    }
48217
public function getUserAllowedRoots()
    {
        $user = $this->getUser();

        if ($user->isAdmin) {
            return null;
        }

        return \array_map('intval', (array) $user->newscategories_roots);
    }
953329
public function getUsers()
    {
        if(!$this->isPropertyAvailable('Users')){
            $this->setProperty("Users", new UserCollection($this->getContext(),new ResourcePathEntity($this->getContext(),$this->getResourcePath() , "Users")));
        }
        return $this->getProperty("Users");
    }
565440
protected function getUser()
    {
        if ($this->_user === null) {
            $this->_user = $this->getClient()->user;
        }
        return $this->_user;
    }
968072
public function getUsers() {
	
		$this->db->setQuery('SELECT * FROM `users` WHERE group_id=?');
		$list = $this->db->loadObjectList($this->id);
	
		$users = array();
	
		$userClass = PAIR_USER_CLASS;
	
		// iterate on each page
		foreach ($list as $row) {
			$users[] = new $userClass($row);
		}
	
		return $users;
	
	}
274409
public function getUserGroups()
    {
        $groups = [];
        foreach ($this->adminGroupConfiguration->getGroups() as $groupName) {
            $groups[] = $this->getUserGroup("$groupName");
        }
        $groups[] = $this->getUserGroup('guest');

        return $groups;
    }
872265
public function getAllUsersIndex()
    {
        $user = new User($this->di->get("db"));
        $users = $user->getAllUsers();

        $views = [
            ["comment/users/view-all", ["users" => $users], "main"]
        ];

        $this->di->get("pageRenderComment")->renderPage([
            "views" => $views,
            "title" => "Coffee users"
        ]);
    }
736358
protected function getUser()
    {
        if ($this->_user === null) {
            $this->_user = User::findByUsername($this->username);
        }

        return $this->_user;
    }
824686
public function all()
    {
        if ( $this->subject == 'user' ) {
            return $this->getUserPermissions( $this->user );
        } elseif ( $this->subject == 'role' ) {
            return $this->getRolePermissions( $this->role );
        }
    }
377435
public function getUser()
    {
        $token = $this->getToken();

        if (!$token) {
            return false;
        }

        $user = $token->getUser();

        if (is_object($user)) {
            return $user;
        }

        return;
    }
150162
public function all()
    {
        $endpoint = '/admin/users.json';
        $response = $this->request($endpoint);
        return $this->createCollection(User::class, $response['users']);
    }
1002501
public function getAllUsers($parameters = array())
    {
        $response = $this->client->get('/v2/user', $parameters);

        $users = array();
        foreach ($response['items'] as $response) {
            $users[] = new User($response);
        }

        return $users;
    }
351612
public function list_users()
    {
        if (!$this->is_loggedin) {
            return false;
        }

        $response = $this->exec_curl('/api/s/' . $this->site . '/list/user');

        return $this->process_response($response);
    }
44728
public function users()
    {
        return $this
            ->belongsToMany(
                config('laravel-auth.users.model', User::class),
                $this->getPrefix().config('laravel-auth.role-user.table', 'permission_role')
            )
            ->using(Pivots\RoleUser::class)
            ->withTimestamps();
    }
162273
public function users()
    {
        //Only admins and managers can access this controller
        if (!$this->Auth->isGroup(['admin', 'manager'])) {
            return;
        }

        $links[] = [__d('me_cms', 'List users'), [
            'controller' => 'Users',
            'action' => 'index',
            'plugin' => 'MeCms',
            'prefix' => ADMIN_PREFIX,
        ]];
        $links[] = [__d('me_cms', 'Add user'), [
            'controller' => 'Users',
            'action' => 'add',
            'plugin' => 'MeCms',
            'prefix' => ADMIN_PREFIX,
        ]];

        //Only admins can access these actions
        if ($this->Auth->isGroup('admin')) {
            $links[] = [__d('me_cms', 'List groups'), [
                'controller' => 'UsersGroups',
                'action' => 'index',
                'plugin' => 'MeCms',
                'prefix' => ADMIN_PREFIX,
            ]];
            $links[] = [__d('me_cms', 'Add group'), [
                'controller' => 'UsersGroups',
                'action' => 'add',
                'plugin' => 'MeCms',
                'prefix' => ADMIN_PREFIX,
            ]];
        }

        return [$links, I18N_USERS, ['icon' => 'users']];
    }
401403
public function getAllUsers($withAdmin = false)
    {
        $query = $this->userModel->query()
            ->orderBy('email');

        if ( ! $withAdmin) {
            $query->where('is_superadmin', false);
        }

        return $query->get();
    }
849793
public function getClients()
  {
    $clients = array();

    $this->Client->byOrganization($this->AuthenticationManager->getCurrentUserOrganizationId())->each(function($Client) use (&$clients)
    {
      array_push($clients, array('label'=> $Client->name , 'value'=>$Client->id));
    });

    return $clients;
  }