Bitrix-D7
23.9
Загрузка...
Поиск...
Не найдено
google.php
1
<?php
2
3
namespace
Bitrix\Pull\Push\Service
;
4
5
use
Bitrix\Pull\Push\Message\GoogleMessage
;
6
7
class
Google
extends
BaseService
8
{
9
function
__construct
()
10
{
11
$this->allowEmptyMessage =
false
;
12
}
13
21
public
function
getBatch
(array $messages = []): string
22
{
23
$arGroupedMessages =
self::getGroupedByAppID
($messages);
24
if
(empty($arGroupedMessages))
25
{
26
return
''
;
27
}
28
29
$batch = $this->
getBatchWithModifier
($arGroupedMessages,
";3;"
);
30
31
if
($batch ==
''
)
32
{
33
return
$batch;
34
}
35
36
return
$batch;
37
}
38
45
function
getMessageInstance
($token):
GoogleMessage
46
{
47
return
new
GoogleMessage
($token);
48
}
49
50
public
static
function
shouldBeSent
($messageRowData): bool
51
{
52
return
true
;
53
}
54
}
Bitrix\Pull\Push\Message\GoogleMessage
Definition
googlemessage.php:6
Bitrix\Pull\Push\Service\BaseService
Definition
baseservice.php:10
Bitrix\Pull\Push\Service\BaseService\getGroupedByAppID
static getGroupedByAppID($arMessages)
Definition
baseservice.php:88
Bitrix\Pull\Push\Service\BaseService\getBatchWithModifier
getBatchWithModifier($appMessages=Array(), $modifier="")
Definition
baseservice.php:14
Bitrix\Pull\Push\Service\Google
Definition
google.php:8
Bitrix\Pull\Push\Service\Google\__construct
__construct()
Definition
google.php:9
Bitrix\Pull\Push\Service\Google\shouldBeSent
static shouldBeSent($messageRowData)
Definition
google.php:50
Bitrix\Pull\Push\Service\Google\getBatch
getBatch(array $messages=[])
Definition
google.php:21
Bitrix\Pull\Push\Service\Google\getMessageInstance
getMessageInstance($token)
Definition
google.php:45
Bitrix\Pull\Push\Service
Definition
apple.php:3
modules
pull
lib
push
service
google.php
Создано системой
1.10.0