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


PHP UserManagerInterface::findUsers方法代码示例

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


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

示例1: getCollection

 /**
  * Returns all users in a single collection resource.
  *
  * @param string[] $options
  *
  * @return Resource
  */
 public function getCollection(array $options = array())
 {
     /** @var UserEntity[] $collection */
     $collection = $this->userManager->findUsers();
     $resource = new Resource($this->generateBrowseUrl(), array('count' => count($collection)));
     foreach ($collection as $element) {
         $resource->setEmbedded('user', $this->createResourceFromUser($element));
     }
     return $resource;
 }
开发者ID:ingewikkeld,项目名称:rest-user-bundle,代码行数:17,代码来源:User.php

示例2: deteleAll

 public function deteleAll()
 {
     $users = $this->userManager->findUsers();
     foreach ($users as $user) {
         $this->userManager->deleteUser($user);
     }
 }
开发者ID:bixlabs,项目名称:concepto-sises,代码行数:7,代码来源:UserManipulator.php

示例3: getPrincipalsByPrefix

 /**
  * Returns a list of principals based on a prefix.
  *
  * This prefix will often contain something like 'principals'. You are only
  * expected to return principals that are in this base path.
  *
  * You are expected to return at least a 'uri' for every user, you can
  * return any additional properties if you wish so. Common properties are:
  *   {DAV:}displayname
  *   {http://sabredav.org/ns}email-address - This is a custom SabreDAV
  *     field that's actually injected in a number of other properties. If
  *     you have an email address, use this property.
  *
  * @param string $prefixPath
  *
  * @return array
  */
 public function getPrincipalsByPrefix($prefixPath)
 {
     $userlist = $this->user_manager->findUsers();
     $principals = array();
     foreach ($userlist as $user) {
         // due to the lack of the implementation of prefixes, return all users
         $principals[] = $this->getPrincipalArray($user);
     }
     return $principals;
 }
开发者ID:bartv2,项目名称:SecotrustSabreDavBundle,代码行数:27,代码来源:PrincipalBackend.php

示例4: all

 /**
  * @inheritdoc
  */
 public function all($limit = null, $offset = null)
 {
     return $this->FOSUserManager->findUsers();
 }
开发者ID:viettut,项目名称:todo,代码行数:7,代码来源:LecturerManager.php


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