首页
学习
活动
专区
工具
TVP
发布
精选内容/技术社群/优惠产品,尽在小程序
立即前往

ReflectionClass::getConstants

(PHP 5, PHP 7)

ReflectionClass::getConstants - 获取常量

描述

代码语言:javascript
复制
public array ReflectionClass::getConstants ( void )

获取类中的所有已定义的常量,而不管它们的可见性如何。

参数

该函数没有参数。

返回值

一个常量的数组,其中键的名称和值是常量的值。

另请参阅

  • ReflectionClass::getConstant() - 获取定义的常量

← ReflectionClass::getConstant

ReflectionClass::getConstructor →

扫码关注腾讯云开发者

领取腾讯云代金券

http://www.vxiaotou.com