Better PHP Documentation
opinionated
Open main menu
Get Started
Documentation
Community
Training
Better PHP Documentation
Close menu
Get Started
Documentation
Community
Training
Log in
Язык:
English
German
Spanish
French
Italian
Japanese
Brazilian Portuguese
Russian
Turkish
Ukrainian
Chinese (Simplified)
Other
Класс ReflectionConstant
(PHP 8 >= 8.4.0)
Введение
Класс
ReflectionConstant
сообщает информацию о глобальной константе.
Обзор класса
class
ReflectionConstant
implements
Reflector
{
/* Свойства */
public
string
$
name
;
/* Методы */
public
function
__construct
(
string
$name
)
public
function
getExtension
():
?
ReflectionExtension
public
function
getExtensionName
():
string
|
false
public
function
getFileName
():
string
|
false
public
function
getName
():
string
public
function
getNamespaceName
():
string
public
function
getShortName
():
string
public
function
getValue
():
mixed
public
function
isDeprecated
():
bool
public
function
__toString
():
string
}
Свойства
name
Имя константы. Доступно только для чтения, при попытке записи выбрасывается исключение
ReflectionException
.
Список изменений
Версия
Описание
8.5.0
Класс больше не является окончательным (final).
Смотрите также
ReflectionClassConstant
Содержание
ReflectionConstant::__construct
— Создаёт объект класса ReflectionConstant
ReflectionConstant::getExtension
— Получает объект класса ReflectionExtension определяющего модуль
ReflectionConstant::getExtensionName
— Получает имя модуля
ReflectionConstant::getFileName
— Получает имя файла
ReflectionConstant::getName
— Получает имя константы
ReflectionConstant::getNamespaceName
— Получает имя пространства имён
ReflectionConstant::getShortName
— Получает короткое имя
ReflectionConstant::getValue
— Получает значение
ReflectionConstant::isDeprecated
— Проверяет, не устарела ли константа
ReflectionConstant::__toString
— Возвращает строковое представление
Нашли ошибку?
Инструкция
•
Исправление
•
Сообщение об ошибке
+
Добавить
Примечания пользователей
Пользователи ещё не добавляли примечания для страницы
0
pcntl_sigtimedwait
Waits for signals, with a timeout
0
similar_text
Calculate the similarity between two strings
0
boolval
Get the boolean value of a variable
0
curl_multi_close
Close a set of cURL handles
0
imap_body
Read the message body
0
mb_strpos
Find position of first occurrence of string in a string
0
pg_send_prepare
Sends a request to create a prepared statement with the given parameters, without waiting for completion
0
swoole_native_socket_bind
0
Arr::prependKeysWith
0
zend_version
Gets the version of the current Zend engine
^