コード例 #1
0
 /**
  * @param InputInterface  $input
  * @param OutputInterface $output
  * @param User            $user
  * @param QuestionHelper  $questionHelper
  *
  * @return User
  */
 protected function editGoogleLogin(InputInterface $input, OutputInterface $output, User $user, QuestionHelper $questionHelper)
 {
     $googleLoginQuestion = new Question('Google Login: ');
     $user->setGoogleLogin($questionHelper->ask($input, $output, $googleLoginQuestion));
     return $user;
 }
コード例 #2
0
 /**
  * @param string $realName
  * @param string $email
  * @param array  $roles
  *
  * @return User
  */
 public function createUser($realName, $email, array $roles)
 {
     $user = new User();
     $user->setRealName($realName);
     $user->setEmail($email);
     $user->setRoles($roles);
     return $user;
 }