Bitrix API

Params extends Registry

Tags
implements

Table of Contents

Constants

CHAT_PARAMS  = [self::IS_COPILOT, self::COPILOT_ROLES, self::COPILOT_MAIN_ROLE]
COPILOT_MAIN_ROLE  = 'COPILOT_MAIN_ROLE'
COPILOT_ROLES  = 'COPILOT_ROLES'
EVENT_CHAT_PARAM_INIT  = 'OnChatParamInit'
IS_COPILOT  = 'IS_COPILOT'

Methods

addParamByArray()  : Result
addParamByName()  : Result
addParamByObject()  : Result
cleanCache()  : void
deleteAll()  : Params
Drops all message params.
deleteParam()  : Params
filter()  : $this
get()  : Param|null
getAny()  : T|null
getChatId()  : int
getInstance()  : Params
isCreated()  : bool
isValidParamName()  : bool
loadWithoutChat()  : self
merge()  : static
saveWithNewChatId()  : Result
setChatId()  : self
setIsCreated()  : void
toRestFormat()  : array<string|int, mixed>
unsetByKeys()  : void
updateParam()  : Result

Constants

CHAT_PARAMS

public mixed CHAT_PARAMS = [self::IS_COPILOT, self::COPILOT_ROLES, self::COPILOT_MAIN_ROLE]

COPILOT_MAIN_ROLE

public mixed COPILOT_MAIN_ROLE = 'COPILOT_MAIN_ROLE'

COPILOT_ROLES

public mixed COPILOT_ROLES = 'COPILOT_ROLES'

EVENT_CHAT_PARAM_INIT

public mixed EVENT_CHAT_PARAM_INIT = 'OnChatParamInit'

IS_COPILOT

public mixed IS_COPILOT = 'IS_COPILOT'

Methods

addParamByArray()

public addParamByArray(array<string|int, mixed>|null $chatParams) : Result
Parameters
$chatParams : array<string|int, mixed>|null
Return values
Result

addParamByName()

public addParamByName(string $paramName, mixed $paramValue) : Result
Parameters
$paramName : string
$paramValue : mixed
Return values
Result

cleanCache()

public static cleanCache(int $chatId) : void
Parameters
$chatId : int

deleteParam()

public deleteParam(string $paramName) : Params
Parameters
$paramName : string
Return values
Params

filter()

public filter(callable $predicate) : $this
Parameters
$predicate : callable
Return values
$this

get()

public get(string $paramName) : Param|null
Parameters
$paramName : string
Return values
Param|null

getAny()

public getAny() : T|null
Return values
T|null

getChatId()

public getChatId() : int
Return values
int

getInstance()

public static getInstance(int $chatId) : Params
Parameters
$chatId : int
Return values
Params

isCreated()

public isCreated() : bool
Return values
bool

isValidParamName()

public isValidParamName(string $paramName) : bool
Parameters
$paramName : string
Return values
bool

loadWithoutChat()

public static loadWithoutChat(array<string|int, mixed> $source) : self
Parameters
$source : array<string|int, mixed>
Return values
self

merge()

public merge(Registry<string|int, T$registry) : static
Parameters
$registry : Registry<string|int, T>
Return values
static

saveWithNewChatId()

public saveWithNewChatId(int $chatId) : Result
Parameters
$chatId : int
Return values
Result

setChatId()

public setChatId(int $chatId) : self
Parameters
$chatId : int
Return values
self

setIsCreated()

public setIsCreated(bool $isCreated) : void
Parameters
$isCreated : bool

toRestFormat()

public toRestFormat() : array<string|int, mixed>
Return values
array<string|int, mixed>

unsetByKeys()

public unsetByKeys(array<string|int, mixed> $keys) : void
Parameters
$keys : array<string|int, mixed>

updateParam()

public updateParam(string $paramName, mixed $paramValue) : Result
Parameters
$paramName : string
$paramValue : mixed
Return values
Result

        
On this page

Search results