“var_dump”功能
通过函数名称本身,var_dump()
转储有关所提供参数的所有内容(对象的函数除外)。
有没有办法转储这些功能?
by the function name itself, var_dump()
dumps everything about a provided parameter EXCEPT the functions of an object.
is there a way of dumping out these functions?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
您无法获取对象的方法,但可以获取类方法:
或
You cannot get the object's methods, but you can get the class methods:
or
PHP 有一个
class_get_methods()
函数和一个反射 API。两者都应该足够了。PHP has a
class_get_methods()
function and a reflection API. Either should suffice.您也可以使用 ReflectionClass API
示例:
You can use ReflectionClass API too
An Example: