PHP Класс PartKeepr\AuthBundle\Services\UserService

Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
__construct ( Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorage $tokenStorage, EntityManager $entityManager, FOS\UserBundle\Util\UserManipulator $userManipulator, FOS\UserBundle\Model\UserManagerInterface $userManager, $userLimit = false )
checkUserLimit ( ) : boolean Checks if the amount of users is exceeded.
deleteFOSUser ( User $user ) Deletes an user from the FOSUser system.
getBuiltinProvider ( )
getProvider ( $providerClass )
getProviderByType ( $type )
getProviderTypeByClass ( $providerClass )
getProxyUser ( $username, UserProvider $provider, boolean | false $create = false ) : mixed | User Returns the proxy user for a given username and provider.
getUser ( ) : User Returns the PartKeeprUser based on the user token within the Symfony2 environment.
getUserCount ( ) : mixed Returns the number of users present in the system.
protect ( User $user ) Protects a given user against changes.
syncData ( User $user ) Syncronizes the data of the given user with the FOSRestBundle.
unprotect ( User $user ) Unprotects a given user against changes.

Приватные методы

Метод Описание
createProxyUser ( $username, $provider )

Описание методов

__construct() публичный Метод

public __construct ( Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorage $tokenStorage, EntityManager $entityManager, FOS\UserBundle\Util\UserManipulator $userManipulator, FOS\UserBundle\Model\UserManagerInterface $userManager, $userLimit = false )
$tokenStorage Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorage
$entityManager Doctrine\ORM\EntityManager
$userManipulator FOS\UserBundle\Util\UserManipulator
$userManager FOS\UserBundle\Model\UserManagerInterface

checkUserLimit() публичный Метод

Checks if the amount of users is exceeded.
public checkUserLimit ( ) : boolean
Результат boolean

deleteFOSUser() публичный Метод

Deletes an user from the FOSUser system.
public deleteFOSUser ( User $user )
$user PartKeepr\AuthBundle\Entity\User

getBuiltinProvider() публичный Метод

public getBuiltinProvider ( )

getProvider() публичный Метод

public getProvider ( $providerClass )

getProviderByType() публичный Метод

public getProviderByType ( $type )

getProviderTypeByClass() публичный Метод

public getProviderTypeByClass ( $providerClass )

getProxyUser() публичный Метод

Returns the proxy user for a given username and provider.
public getProxyUser ( $username, UserProvider $provider, boolean | false $create = false ) : mixed | User
$username
$provider PartKeepr\AuthBundle\Entity\UserProvider
$create boolean | false If set to true
Результат mixed | PartKeepr\AuthBundle\Entity\User

getUser() публичный Метод

Returns the PartKeeprUser based on the user token within the Symfony2 environment.
public getUser ( ) : User
Результат PartKeepr\AuthBundle\Entity\User The proxy user

getUserCount() публичный Метод

Returns the number of users present in the system.
public getUserCount ( ) : mixed
Результат mixed

protect() публичный Метод

Protects a given user against changes.
public protect ( User $user )
$user PartKeepr\AuthBundle\Entity\User

syncData() публичный Метод

Syncronizes the data of the given user with the FOSRestBundle.
public syncData ( User $user )
$user PartKeepr\AuthBundle\Entity\User

unprotect() публичный Метод

Unprotects a given user against changes.
public unprotect ( User $user )
$user PartKeepr\AuthBundle\Entity\User