说明:Laravel中经常使用PHP的反射特性来设计代码,本文主要学习PHP的反射特性,来提高写代码时的设计质量。...PHP提供一套检测class, interface, trait, property, method的两个工具包:Introspection Functions和Reflection API,类似于探针一样的东西来探测这些一等公民...即反射来检测class, interface, trait, property, method,这些API是好几个类组成的,提供了很多好用的方法。...总结:本文主要聊了下PHP提供的一套检测class, interface, trait, property, method的两个工具包:Introspection Functions和Reflection...下篇再聊下Reflection API的使用,到时见。