当前位置: 首页>>代码示例>>PHP>>正文


PHP UserInterface::getEmail方法代码示例

本文整理汇总了PHP中Symfony\Component\Security\Core\User\UserInterface::getEmail方法的典型用法代码示例。如果您正苦于以下问题:PHP UserInterface::getEmail方法的具体用法?PHP UserInterface::getEmail怎么用?PHP UserInterface::getEmail使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Symfony\Component\Security\Core\User\UserInterface的用法示例。


在下文中一共展示了UserInterface::getEmail方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: getAuthorEmail

 public function getAuthorEmail()
 {
     if (null === $this->author) {
         return $this->author_email;
     }
     return $this->author->getEmail();
 }
开发者ID:bamper,项目名称:symfony2pros.com,代码行数:7,代码来源:Tutorial.php

示例2: isEqualTo

 public function isEqualTo(UserInterface $user)
 {
     if (!$user instanceof LdapUser || $user->getUsername() !== $this->username || $user->getEmail() !== $this->email || count(array_diff($user->getRoles(), $this->roles)) > 0 || $user->getDn() !== $this->dn) {
         return false;
     }
     return true;
 }
开发者ID:redventures-oss,项目名称:LdapBundle,代码行数:7,代码来源:LdapUser.php

示例3: authorizeUser

 public function authorizeUser(UserInterface $authenticatedUser)
 {
     $user = $this->userManager->findUserByEmail($authenticatedUser->getEmail());
     if (null == $user) {
         throw new FailureAuthorizedException(401, "XSolve Google Auth couldn't authorize user. User doesn't exists");
     }
     return $user;
 }
开发者ID:xsolve-pl,项目名称:xsolve-google-auth-bundle,代码行数:8,代码来源:GoogleAuthorizer.php

示例4: createVanillaUser

 /**
  * @param UserInterface $user
  * @return VanillaUser
  */
 public function createVanillaUser(UserInterface $user)
 {
     /** @var $user \FOS\UserBundle\Model\User */
     $vanillaUser = new VanillaUser($user->getUsername());
     $vanillaUser->setEmail($user->getEmail());
     if ($user->isSuperAdmin()) {
         $vanillaUser->setRoles([VanillaUser::ROLE_MEMBER, VanillaUser::ROLE_ADMINISTRATOR]);
     }
     return $vanillaUser;
 }
开发者ID:elpum,项目名称:TgaForumBundle,代码行数:14,代码来源:FOSUserTransformer.php

示例5: notifyLateEmployee

 public function notifyLateEmployee(UserInterface $user, Schedule $schedule)
 {
     $supervisors = $user->getSupervisors();
     foreach ($supervisors as $supervisor) {
         $context = array('user' => $user, 'supervisor' => $supervisor, 'position' => $schedule->getPosition());
         $this->dispatchMessage('OpenSkedgeBundle:Mailer:lateemployee_sup.txt.twig', $context, $this->parameters['senderEmail'], $supervisor->getEmail());
     }
     $context = array('user' => $user, 'position' => $schedule->getPosition());
     $this->dispatchMessage('OpenSkedgeBundle:Mailer:lateemployee_emp.txt.twig', $context, $this->parameters['senderEmail'], $user->getEmail());
 }
开发者ID:edubacco,项目名称:OpenSkedge,代码行数:10,代码来源:TwigMailer.php

示例6: sendNewPasswordMail

 /**
  * Method to send a mail to the user that his account has been created
  * or that his password has been reset.
  *
  * @param UserInterface $user
  * @param boolean $isReset
  */
 public function sendNewPasswordMail(UserInterface $user, $isReset = false)
 {
     $applicationName = $this->options['applicationName'];
     $subject = '[' . ($applicationName !== null && $applicationName != 'OPIT-HRM' ? $applicationName : 'OPIT-HRM') . '] - New account created';
     $template = 'newAccount';
     if ($isReset) {
         $subject = '[' . ($applicationName !== null && $applicationName != 'OPIT-HRM' ? $applicationName : 'OPIT-HRM') . '] - Password reset';
         $template = 'passwordReset';
     }
     $this->mail->setRecipient($user->getEmail());
     $this->mail->setSubject($subject);
     $this->mail->setBodyByTemplate('OpitOpitHrmUserBundle:Mail:' . $template . '.html.twig', array('password' => $this->password, 'user' => $user));
     $this->mail->sendMail();
 }
开发者ID:hkmshb,项目名称:OpitHrm,代码行数:21,代码来源:UserService.php

示例7: equals

 public function equals(UserInterface $user)
 {
     if (!$user instanceof LdapUser) {
         return false;
     }
     if ($user->getUsername() !== $this->username) {
         return false;
     }
     if ($user->getEmail() !== $this->email) {
         return false;
     }
     if ($user->getRoles() !== $this->roles) {
         return false;
     }
     if ($user->getDn() !== $this->dn) {
         return false;
     }
     return true;
 }
开发者ID:rtoledof,项目名称:LdapBundle,代码行数:19,代码来源:LdapUser.php

示例8: sendPaymentRequest

 public function sendPaymentRequest(PaymentRequest $paymentRequest, UserInterface $user)
 {
     $message = $this->createMessage($paymentRequest->getTitle(), $user->getEmail(), 'CivixCoreBundle:Email:payment_request.html.twig', ['paymentRequest' => $paymentRequest, 'user' => $user, 'domain' => $this->domain]);
     $this->mailer->send($message);
 }
开发者ID:shakaran,项目名称:powerline-server,代码行数:5,代码来源:EmailSender.php

示例9: isEqualTo

 public function isEqualTo(UserInterface $user)
 {
     return $this->email === $user->getEmail();
 }
开发者ID:marwahamdoun,项目名称:Entity,代码行数:4,代码来源:Jobowner.php

示例10: isEqualTo

 /**
  * @inheritDoc
  */
 public function isEqualTo(UserInterface $user)
 {
     if (!$user instanceof User) {
         return false;
     }
     if ($this->password !== $user->getPassword()) {
         return false;
     }
     if ($this->username !== $user->getUsername()) {
         return false;
     }
     if ($this->email !== $user->getEmail()) {
         return false;
     }
     return true;
 }
开发者ID:vardius,项目名称:user-bundle,代码行数:19,代码来源:User.php

示例11: equals

 /**
  * Método requerido por la interfaz UserInterface
  */
 function equals(\Symfony\Component\Security\Core\User\UserInterface $usuario)
 {
     return $this->getEmail() == $usuario->getEmail();
 }
开发者ID:neozoe,项目名称:Cupon,代码行数:7,代码来源:Usuario.php

示例12: getEmail

 /**
  * Returns the users email or as a fallback the installation-email-adress.
  *
  * @param UserInterface $user
  *
  * @return string
  */
 private function getEmail(UserInterface $user)
 {
     if ($user->getEmail() !== null) {
         return $user->getEmail();
     }
     return $this->container->getParameter('sulu_admin.email');
 }
开发者ID:sulu,项目名称:sulu,代码行数:14,代码来源:ResettingController.php

示例13: equals

    /**
     * @param UserInterface $user
     * @return Boolean
     */
    function equals(UserInterface $user)
    {
        if (!$user instanceof User) {
            return false;
        }
        
        if ($this->email !== $user->getEmail()) {
            return false;
        }

        if ($this->password !== $user->getPassword()) {
            return false;
        }

        if ($this->getSalt() !== $user->getSalt()) {
            return false;
        }

        return true;
    }
开发者ID:ndusan,项目名称:tbq,代码行数:24,代码来源:User.php

示例14: equals

 /**
  * equals.
  *
  * @param UserInterface $account
  * @return bool
  */
 public function equals(\Symfony\Component\Security\Core\User\UserInterface $account)
 {
     if ($account->getUsername() != $this->getUsername()) {
         return false;
     }
     if ($account->getEmail() != $this->getEmail()) {
         return false;
     }
     return true;
 }
开发者ID:rtxwebdev1,项目名称:UserBundle,代码行数:16,代码来源:User.php

示例15: equals

 /**
  * equals.
  *
  * @param UserInterface $account
  * @return bool
  */
 public function equals(UserInterface $account)
 {
     if ($account->getUsername() != $this->getUsername()) {
         return false;
     }
     if ($account->getEmail() != $this->getEmail()) {
         return false;
     }
     return true;
 }
开发者ID:robertowest,项目名称:CuteFlow-V4,代码行数:16,代码来源:User.php


注:本文中的Symfony\Component\Security\Core\User\UserInterface::getEmail方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。