setName('organization-folders:resource-members:list') ->addArgument('resource-id', InputArgument::REQUIRED, 'Id of Resource') ->setDescription('List all members of resource.'); parent::configure(); } protected function execute(InputInterface $input, OutputInterface $output): int { try { $resourceId = $input->getArgument('resource-id'); $members = $this->resourceMemberService->findAll($resourceId); $this->writeTableInOutputFormat($input, $output, $this->formatTableSerializables($members)); return 0; } catch (Exception $e) { $output->writeln("Exception \"{$e->getMessage()}\" at {$e->getFile()} line {$e->getLine()}"); return 1; } } }