Contentserv PHP API

CSTokenPasswordAppContext extends CSTokenAppContext
in package

This class represents a concrete token context

Tags
access

public

since

CS21.7

Table of Contents

__toString()  : string
Generates the string representation of the token context.
check()  : bool
Checks if the token context instance is valid for the current context.
createForAppContext()  : CSTokenAppContext
Initializes the context with valid apps.
createForModuleContext()  : CSTokenModuleContext
Initializes the context with the matching module name.
createForPasswordAppContext()  : CSTokenPasswordAppContext
Initializes the context with a reset id.
createForRestContext()  : CSTokenRestContext
Initializes the token context with valid endpoints.
createFromDefinition()  : CSTokenContext
Restores a token context from the definition stored in the string representation.
getResetId()  : string
Returns the stored reset id
setApps()  : void
Sets the apps that are valid for this context.
setEndpoints()  : void
Sets the valid endpoints for this context.
setModule()  : void
Sets the module name for this context.
setResetId()  : void
Sets the reset id needed for this context.

Methods

__toString()

Generates the string representation of the token context.

public final __toString() : string
Tags
access

public

Return values
string

String representation of the token context.

check()

Checks if the token context instance is valid for the current context.

public final check() : bool
Tags
access

public

Return values
bool

True, if token context matches the context, otherwise false.

createForAppContext()

Initializes the context with valid apps.

public static createForAppContext(array<string|int, mixed> $aApps) : CSTokenAppContext
Parameters
$aApps : array<string|int, mixed>
Tags
access

public

Return values
CSTokenAppContext

The token context instance.

createForModuleContext()

Initializes the context with the matching module name.

public final static createForModuleContext(string $sModule) : CSTokenModuleContext
Parameters
$sModule : string

The module name valid for this context.

Tags
access

public

Return values
CSTokenModuleContext

The concrete token context instance.

createForRestContext()

Initializes the token context with valid endpoints.

public static createForRestContext(array<string|int, mixed> $aEndpoints) : CSTokenRestContext
Parameters
$aEndpoints : array<string|int, mixed>

The valid endpoints for this context.

Tags
access

public

Return values
CSTokenRestContext

The concrete token context.

createFromDefinition()

Restores a token context from the definition stored in the string representation.

public final static createFromDefinition(array<string|int, mixed> $aDefinition) : CSTokenContext
Parameters
$aDefinition : array<string|int, mixed>

The token context definition retrieved from string representation.

Tags
access

public

Return values
CSTokenContext

A concrete instance of CSToken Context.

setApps()

Sets the apps that are valid for this context.

public setApps(array<string|int, mixed> $aApps) : void
Parameters
$aApps : array<string|int, mixed>
Tags
access

public

Return values
void

setEndpoints()

Sets the valid endpoints for this context.

public setEndpoints(array<string|int, mixed> $aEndpoints) : void
Parameters
$aEndpoints : array<string|int, mixed>

The valid enpoints for this context.

Tags
access

public

Return values
void

setModule()

Sets the module name for this context.

public setModule(string $sModule) : void
Parameters
$sModule : string

The module name for this context.

Tags
access

public

Return values
void

setResetId()

Sets the reset id needed for this context.

public setResetId(string $sResetId) : void
Parameters
$sResetId : string

The user's reset Id.

Tags
access

public

Return values
void

        

Search results