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


PHP User::getFullName方法代码示例

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


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

示例1: testCreateNewEntity

 /**
  * Test creation of new entity
  */
 public function testCreateNewEntity()
 {
     $user = new User();
     $this->assertNull($user->getId());
     $this->assertFalse($user->isEnabled());
     $this->assertNull($user->getCreatedAt());
     $this->assertNull($user->getUpdatedAt());
     $this->assertNull($user->getFullName());
     $this->assertNull($user->getPhone());
 }
开发者ID:stfalcon-studio,项目名称:rock-events,代码行数:13,代码来源:UserTest.php

示例2: testEmptyUser

 /**
  * Test an empty User entity
  */
 public function testEmptyUser()
 {
     $user = new User();
     $this->assertEquals('New User', $user->__toString());
     $this->assertNull($user->getId());
     $this->assertNull($user->getFullName());
     $this->assertNull($user->getFacebookAccessToken());
     $this->assertNull($user->getFacebookId());
     $this->assertEquals(0, $user->getItems()->count());
 }
开发者ID:stfalcon-studio,项目名称:lost-and-found,代码行数:13,代码来源:UserTest.php

示例3: checkAccess

 public function checkAccess(CrudEvent $event)
 {
     if (!$this->user instanceof User) {
         return;
     }
     $data = $event->getData();
     if ($data instanceof FormInterface) {
         $data = $data->getData();
     }
     if ($data instanceof User) {
         if ($data !== $this->user) {
             throw new AccessDeniedException($this->user->getFullName() . ' is not allowed to update ' . $data->getFullName());
         }
     } elseif (method_exists($data, 'getUser') && $this->user !== $data->getUser()) {
         throw new AccessDeniedException($this->user->getFullName() . ' is not allowed to update ' . $data->getFullName() . '\'s data');
     } elseif (method_exists($data, 'getAuthor') && $this->user !== $data->getAuthor()) {
         throw new AccessDeniedException($this->user->getFullName() . ' is not allowed to update ' . $data->getFullName() . '\'s data');
     }
 }
开发者ID:BeerCoders,项目名称:portfolio-api,代码行数:19,代码来源:CrudSubscriber.php

示例4: getFullName

 /**
  * {@inheritDoc}
  */
 public function getFullName()
 {
     $this->__initializer__ && $this->__initializer__->__invoke($this, 'getFullName', array());
     return parent::getFullName();
 }
开发者ID:redssie,项目名称:EP_Trgovina,代码行数:8,代码来源:__CG__AppBundleEntityUser.php


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