本文整理汇总了PHP中AppBundle\Entity\User::getLastname方法的典型用法代码示例。如果您正苦于以下问题:PHP User::getLastname方法的具体用法?PHP User::getLastname怎么用?PHP User::getLastname使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类AppBundle\Entity\User
的用法示例。
在下文中一共展示了User::getLastname方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
public function __construct(User $user)
{
$this->id = $user->getId();
$this->firstname = $user->getFirstname();
$this->lastname = $user->getLastname();
$this->email = $user->getEmail();
$this->positionLong = $user->getPositionLong();
$this->positionLat = $user->getPositionLat();
$this->positionCity = $user->getPositionCity();
$this->positionDep = $user->getPositionDep();
$this->positionCountry = $user->getPositionCountry();
$this->photo = $user->getPhoto();
}
示例2: getLastname
/**
* {@inheritDoc}
*/
public function getLastname()
{
$this->__initializer__ && $this->__initializer__->__invoke($this, 'getLastname', []);
return parent::getLastname();
}
示例3: transform
/**
* Turn this item object into a generic array
*
* @return array
*/
public function transform(User $user)
{
return ['id' => (int) $user->getId(), 'username' => $user->getUsername(), 'email' => $user->getEmail(), 'lastLogin' => $user->getLastLogin(), 'enabled' => (bool) $user->isEnabled(), 'firstname' => $user->getFirstname(), 'lastname' => $user->getLastname(), 'fullname' => $user->getFullname(), 'displayname' => $user->getDisplayName()];
}