Platformsh\Cli\Command\User\UserListCommand::execute PHP Метод

execute() защищенный Метод

protected execute ( Symfony\Component\Console\Input\InputInterface $input, Symfony\Component\Console\Output\OutputInterface $output )
$input Symfony\Component\Console\Input\InputInterface
$output Symfony\Component\Console\Output\OutputInterface
    protected function execute(InputInterface $input, OutputInterface $output)
    {
        $this->validateInput($input);
        $project = $this->getSelectedProject();
        $rows = [];
        $i = 0;
        $table = new Table($input, $output);
        foreach ($project->getUsers() as $user) {
            $account = $this->api()->getAccount($user);
            $role = $user['role'];
            $weight = $i++;
            if ($project->owner === $user->id) {
                $weight = -1;
                if (!$table->formatIsMachineReadable()) {
                    $role .= ' (owner)';
                }
            }
            $rows[$weight] = [$account['email'], $account['display_name'], $role];
        }
        ksort($rows);
        $table->render(array_values($rows), ['Email address', 'Name', 'Project role']);
        return 0;
    }
UserListCommand