Bitrix-D7
23.9
Загрузка...
Поиск...
Не найдено
dateconverterresult.php
1
<?php
2
namespace
Bitrix\Main\Text
;
3
8
class
DateConverterResult
9
{
13
private
$date =
null
;
14
18
private
$text =
''
;
19
23
private
$textPosition = 0;
24
28
private
$textLength = 0;
29
33
private
$type =
''
;
34
38
private
$metrics = Array();
39
43
private
$metricModifier = Array();
44
45
const
TYPE_UNKNOWN
=
'UNKNOWN'
;
46
const
TYPE_RELATIVE
=
'RELATIVE'
;
47
const
TYPE_DAYOFWEEK
=
'DAYOFWEEK'
;
48
const
TYPE_MODIFIER
=
'MODIFIER'
;
49
const
TYPE_CALENDAR
=
'CALENDAR'
;
50
const
TYPE_PARTOFDAY
=
'PARTOFDAY'
;
51
60
function
__construct
(\
Bitrix
\Main\
Type
\
DateTime
$date, $matchParams, $type = self::TYPE_UNKNOWN, $metrics = Array(), $metricModifier = Array())
61
{
62
$this->date = $date;
63
$this->type = $type;
64
if
(is_array($matchParams))
65
{
66
$this->text = $matchParams[
'TEXT'
];
67
$this->textPosition = $matchParams[
'POSITION'
];
68
$this->textLength = $matchParams[
'LENGTH'
];
69
}
70
$this->metrics = $metrics;
71
$this->metricModifier = $metricModifier;
72
}
73
79
public
function
getDate
()
80
{
81
return
$this->date;
82
}
83
89
public
function
getText
()
90
{
91
return
$this->text;
92
}
93
99
public
function
getTextPosition
()
100
{
101
return
$this->textPosition;
102
}
103
109
public
function
getTextLength
()
110
{
111
return
$this->textLength;
112
}
113
119
public
function
getType
()
120
{
121
return
$this->type;
122
}
123
129
public
function
getMetrics
()
130
{
131
return
$this->metrics;
132
}
133
139
public
function
getMetricModifier
()
140
{
141
return
$this->metricModifier;
142
}
143
}
Bitrix\Main\Text\DateConverterResult
Definition
dateconverterresult.php:9
Bitrix\Main\Text\DateConverterResult\getTextLength
getTextLength()
Definition
dateconverterresult.php:109
Bitrix\Main\Text\DateConverterResult\getDate
getDate()
Definition
dateconverterresult.php:79
Bitrix\Main\Text\DateConverterResult\__construct
__construct(\Bitrix\Main\Type\DateTime $date, $matchParams, $type=self::TYPE_UNKNOWN, $metrics=Array(), $metricModifier=Array())
Definition
dateconverterresult.php:60
Bitrix\Main\Text\DateConverterResult\TYPE_DAYOFWEEK
const TYPE_DAYOFWEEK
Definition
dateconverterresult.php:47
Bitrix\Main\Text\DateConverterResult\getMetricModifier
getMetricModifier()
Definition
dateconverterresult.php:139
Bitrix\Main\Text\DateConverterResult\TYPE_MODIFIER
const TYPE_MODIFIER
Definition
dateconverterresult.php:48
Bitrix\Main\Text\DateConverterResult\TYPE_RELATIVE
const TYPE_RELATIVE
Definition
dateconverterresult.php:46
Bitrix\Main\Text\DateConverterResult\getType
getType()
Definition
dateconverterresult.php:119
Bitrix\Main\Text\DateConverterResult\TYPE_UNKNOWN
const TYPE_UNKNOWN
Definition
dateconverterresult.php:45
Bitrix\Main\Text\DateConverterResult\getText
getText()
Definition
dateconverterresult.php:89
Bitrix\Main\Text\DateConverterResult\getMetrics
getMetrics()
Definition
dateconverterresult.php:129
Bitrix\Main\Text\DateConverterResult\getTextPosition
getTextPosition()
Definition
dateconverterresult.php:99
Bitrix\Main\Text\DateConverterResult\TYPE_CALENDAR
const TYPE_CALENDAR
Definition
dateconverterresult.php:49
Bitrix\Main\Text\DateConverterResult\TYPE_PARTOFDAY
const TYPE_PARTOFDAY
Definition
dateconverterresult.php:50
Bitrix\Main\Type\DateTime
Definition
datetime.php:9
Bitrix\Main\Text
Definition
base32.php:2
Bitrix\Main\Type
Definition
collection.php:2
Bitrix
modules
main
lib
text
dateconverterresult.php
Создано системой
1.10.0