AbstractSwitcher implements SwitcherInterface uses CacheTrait
AbstractYes
Table of Contents
Interfaces
Constants
Methods
- __construct() : mixed
- get() : SwitcherInterface
- getCode() : string
- getDefaultCode() : string
- getMessage() : string|null
- getSpaceId() : int|null
- getUserId() : int
- getValue() : string
- invalidate() : void
- isEnabled() : bool
- switch() : Result
Constants
TYPE_OFF
public
mixed
TYPE_OFF
= 'N'
TYPE_ON
public
mixed
TYPE_ON
= 'Y'
Methods
__construct()
public
__construct(int $userId, int|null $spaceId, string $code) : mixed
Parameters
- $userId : int
- $spaceId : int|null
- $code : string
get()
public
static get(int $userId, int|null $spaceId, string $code) : SwitcherInterface
Parameters
- $userId : int
- $spaceId : int|null
- $code : string
Return values
SwitcherInterfacegetCode()
public
getCode() : string
Return values
stringgetDefaultCode()
public
abstract static getDefaultCode() : string
Return values
stringgetMessage()
public
getMessage() : string|null
Return values
string|nullgetSpaceId()
public
getSpaceId() : int|null
Return values
int|nullgetUserId()
public
getUserId() : int
Return values
intgetValue()
public
abstract getValue() : string
Return values
stringinvalidate()
public
invalidate() : void
isEnabled()
public
isEnabled() : bool
Return values
boolswitch()
public
switch() : Result