class ImpersonateService (View source)

Impersonate Service

Properties

protected Context $securityContext
protected SessionInterface $session
protected PersistenceManagerInterface $persistenceManager
protected PolicyService $policyService

Methods

void
impersonate(Account $account)

No description

void
restoreOriginalIdentity()

No description

Account|null
getImpersonation()

No description

bool
isActive()

No description

Account|null
getCurrentUser()

No description

Account|null
getOriginalIdentity()

No description

array
getOriginalIdentityRoles()

No description

void
refreshTokens(Account $account = null)

No description

void
writeSession(string $key, string|null $value)

No description

mixed
getSessionData(string $key)

No description

Details

void impersonate(Account $account)

No description

Parameters

Account $account

Return Value

void

Exceptions

SessionNotStartedException

void restoreOriginalIdentity()

No description

Return Value

void

Exceptions

SessionNotStartedException

Account|null getImpersonation()

No description

Return Value

Account|null

Exceptions

SessionNotStartedException

bool isActive()

No description

Return Value

bool

Exceptions

SessionNotStartedException

Account|null getCurrentUser()

No description

Return Value

Account|null

Account|null getOriginalIdentity()

No description

Return Value

Account|null

Exceptions

SessionNotStartedException

array getOriginalIdentityRoles()

No description

Return Value

array

Exceptions

SessionNotStartedException

protected void refreshTokens(Account $account = null)

No description

Parameters

Account $account

Return Value

void

protected void writeSession(string $key, string|null $value)

No description

Parameters

string $key
string|null $value

Return Value

void

Exceptions

SessionNotStartedException

protected mixed getSessionData(string $key)

No description

Parameters

string $key

Return Value

mixed

Exceptions

SessionNotStartedException