我的问题很简单,这里是上下文:
原文链接:https://www.f2er.com/php/137656.htmlhttp://php.net/manual/en/language.oop5.magic.php
Magic Methods
The function names
__construct()
,__destruct()
,__call()
,
__callStatic()
,__get()
,__set()
,__isset()
,__unset()
,__sleep()
,__wakeup()
,__toString(),__invoke(),__set_state() and __clone() are magical in PHP classes. You cannot have functions with these names in
any of your classes unless you want the magic functionality associated
with them.PHP reserves all function names starting with __ as magical. It is recommended that you do not use function names with __ in PHP unless you want some documented magic functionality.
@H_301_33@我得到了这些方法的用途以及如何使用它们.我不明白的是:
…unless you want some documented magic functionality.
@H_301_33@那有什么意思?是否有实际的原因来创建用户定义的__magicMethods()?