Bitrix-D7
23.9
Загрузка...
Поиск...
Не найдено
baserole.php
1
<?php
2
3
namespace
Bitrix\Calendar\Core\Role
;
4
5
use
Bitrix\Calendar\Core\Base\BaseProperty
;
6
7
abstract
class
BaseRole
extends
BaseProperty
implements
RoleEntityInterface
8
{
9
public
const
TYPE
=
'user'
;
10
protected
string
$name
=
''
;
11
protected
?
int
$id
=
null
;
12
13
public
static
function
createInstance
(
string
$name
):
RoleEntityInterface
14
{
15
return
new
static
(
$name
);
16
}
17
18
public
function
__construct
(
string
$name
)
19
{
20
$this->name =
$name
;
21
}
22
26
public
function
toString
(): string
27
{
28
return
$this->
getFullName
();
29
}
30
34
public
function
getFields
(): array
35
{
36
return
[
37
'name'
,
38
'id'
,
39
];
40
}
41
45
public
function
getFullName
(): string
46
{
47
return
$this->name
;
48
}
49
53
public
function
getId
(): ?int
54
{
55
return
$this->id
;
56
}
57
61
public
function
getType
(): string
62
{
63
return
static::TYPE;
64
}
65
70
public
function
setName
(
string
$name
):
BaseRole
71
{
72
$this->name =
$name
;
73
74
return
$this;
75
}
76
81
public
function
setId
(?
int
$id
):
BaseRole
82
{
83
$this->
id
=
$id
;
84
85
return
$this;
86
}
87
}
Bitrix\Calendar\Core\Base\BaseProperty
Definition
baseproperty.php:6
Bitrix\Calendar\Core\Role\BaseRole
Definition
baserole.php:8
Bitrix\Calendar\Core\Role\BaseRole\setId
setId(?int $id)
Definition
baserole.php:81
Bitrix\Calendar\Core\Role\BaseRole\getId
getId()
Definition
baserole.php:53
Bitrix\Calendar\Core\Role\BaseRole\__construct
__construct(string $name)
Definition
baserole.php:18
Bitrix\Calendar\Core\Role\BaseRole\createInstance
static createInstance(string $name)
Definition
baserole.php:13
Bitrix\Calendar\Core\Role\BaseRole\getFullName
getFullName()
Definition
baserole.php:45
Bitrix\Calendar\Core\Role\BaseRole\$id
int $id
Definition
baserole.php:11
Bitrix\Calendar\Core\Role\BaseRole\setName
setName(string $name)
Definition
baserole.php:70
Bitrix\Calendar\Core\Role\BaseRole\toString
toString()
Definition
baserole.php:26
Bitrix\Calendar\Core\Role\BaseRole\$name
string $name
Definition
baserole.php:10
Bitrix\Calendar\Core\Role\BaseRole\getType
getType()
Definition
baserole.php:61
Bitrix\Calendar\Core\Role\BaseRole\TYPE
const TYPE
Definition
baserole.php:9
Bitrix\Calendar\Core\Role\BaseRole\getFields
getFields()
Definition
baserole.php:34
Bitrix\Calendar\Core\Role\RoleEntityInterface
Definition
roleentityinterface.php:6
Bitrix\Calendar\Core\Role
Definition
attendee.php:3
modules
calendar
lib
core
role
baserole.php
Создано системой
1.10.0