1C-Bitrix
25.700.0
Загрузка...
Поиск...
Не найдено
User.php
См. документацию.
1
<?php
2
declare(strict_types=1);
3
4
namespace
Bitrix\Im\V2\Message\Text\BbCode;
5
6
use Bitrix\Im\V2\Entity;
7
use Bitrix\Im\V2\Message\Text\ClosedBbCode;
8
9
final
class
User
extends
ClosedBbCode
10
{
11
private
int
$userId;
12
13
private
function
__construct(
int
$userId,
string
$innerText
)
14
{
15
parent::__construct(
$innerText
);
16
$this->userId = $userId;
17
}
18
19
public
static
function
build
(
int
$userId,
string
$innerText
=
''
): self
20
{
21
return
new
self
($userId,
$innerText
);
22
}
23
24
protected
function
getValue
(): ?string
25
{
26
return
(
string
)
$this->userId
;
27
}
28
29
public
function
toPlain
(): string
30
{
31
if
($this->innerText !==
''
)
32
{
33
return
parent::toPlain();
34
}
35
36
$user
=
Entity\User\User::getInstance
($this->userId);
37
if
(
$user
instanceof
Entity
\
User
\
NullUser
)
38
{
39
return
''
;
40
}
41
42
return
$user
->getName() ??
''
;
43
}
44
45
protected
function
getAdditionalParams
():
array
46
{
47
return
[];
48
}
49
50
public
static
function
getName
(): string
51
{
52
return
'USER'
;
53
}
54
}
$userId
if(!is_object($USER)||! $USER->IsAuthorized()) $userId
Определения
check_mail.php:18
Bitrix\Im\V2\Entity\User\NullUser
Определения
NullUser.php:9
Bitrix\Im\V2\Entity\User\User\getInstance
static getInstance(?int $id)
Определения
User.php:72
Bitrix\Im\V2\Message\Text\BbCode\User\getName
static getName()
Определения
User.php:50
Bitrix\Im\V2\Message\Text\BbCode\User\getAdditionalParams
getAdditionalParams()
Определения
User.php:45
Bitrix\Im\V2\Message\Text\BbCode\User\toPlain
toPlain()
Определения
User.php:29
Bitrix\Im\V2\Message\Text\BbCode\User\getValue
getValue()
Определения
User.php:24
Bitrix\Im\V2\Message\Text\BbCode\User\build
static build(int $userId, string $innerText='')
Определения
User.php:19
Bitrix\Im\V2\Message\Text\ClosedBbCode
Определения
ClosedBbCode.php:7
Bitrix\Im\V2\Message\Text\ClosedBbCode\$innerText
string $innerText
Определения
ClosedBbCode.php:8
array
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
Определения
file_new.php:804
Bitrix\Im\V2\Entity\User
Bitrix\Main\Entity
Определения
ufield.php:9
Bitrix\Main\$user
$user
Определения
mysql_to_pgsql.php:33
bitrix
modules
im
lib
V2
Message
Text
BbCode
User.php
Создано системой
1.14.0