Bitrix-D7 23.9
 
Загрузка...
Поиск...
Не найдено
Mode.php
1<?php
2
4
5class Mode
6{
7 public const EXPERIMENTAL = 0;
8 public const INTERCEPTION = 1;
9
10 public static function isMode($mode): bool
11 {
12 $ref = new \ReflectionClass(__CLASS__);
13 $constants = array_flip($ref->getConstants());
14
15 return isset($constants[$mode]);
16 }
17}