Bitrix-D7
23.9
Загрузка...
Поиск...
Не найдено
jointlink.php
1
<?php
2
3
namespace
Bitrix\Calendar\Sharing\Link\Joint
;
4
5
use
Bitrix\Calendar\Sharing\Link\Link
;
6
use
Bitrix\Calendar\Sharing\Link\Member\Member
;
7
8
abstract
class
JointLink
extends
Link
9
{
11
private
array $members = [];
13
private
?
string
$membersHash =
null
;
14
15
public
function
getMembers
(): array
16
{
17
return
$this->members;
18
}
19
20
public
function
setMembers
(array $members): self
21
{
22
foreach
($members as $key => $value)
23
{
24
if
(!($value instanceof
Member
) || $value->getId() === $this->getOwnerId())
25
{
26
unset($members[$key]);
27
}
28
}
29
$this->members = $members;
30
31
return
$this;
32
}
33
34
public
function
getMembersHash
(): ?string
35
{
36
return
$this->membersHash;
37
}
38
39
public
function
setMembersHash
(?
string
$membersHash): static
40
{
41
$this->membersHash = $membersHash;
42
43
return
$this;
44
}
45
46
public
function
isJoint
(): bool
47
{
48
return
!empty($this->members);
49
}
50
51
abstract
public
function
getOwnerId
(): int;
52
}
Bitrix\Calendar\Sharing\Link\Joint\JointLink
Definition
jointlink.php:9
Bitrix\Calendar\Sharing\Link\Joint\JointLink\getMembersHash
getMembersHash()
Definition
jointlink.php:34
Bitrix\Calendar\Sharing\Link\Joint\JointLink\setMembers
setMembers(array $members)
Definition
jointlink.php:20
Bitrix\Calendar\Sharing\Link\Joint\JointLink\setMembersHash
setMembersHash(?string $membersHash)
Definition
jointlink.php:39
Bitrix\Calendar\Sharing\Link\Joint\JointLink\isJoint
isJoint()
Definition
jointlink.php:46
Bitrix\Calendar\Sharing\Link\Joint\JointLink\getOwnerId
getOwnerId()
Bitrix\Calendar\Sharing\Link\Joint\JointLink\getMembers
getMembers()
Definition
jointlink.php:15
Bitrix\Calendar\Sharing\Link\Link
Definition
link.php:8
Bitrix\Calendar\Sharing\Link\Member\Member
Definition
member.php:6
Bitrix\Calendar\Sharing\Link\Joint
Definition
jointlink.php:3
modules
calendar
lib
sharing
link
joint
jointlink.php
Создано системой
1.10.0