Yay! The idea was first committed back on 3rd June 2015, and after quite some time, work and effort, Roave's Better Reflection has finally reached 1.0.0 release.

Better Reflection is a library that mimics the core reflection API in PHP, but adds many additional features and capabilities that are not possible in the core reflection API. Better Reflection has lots of potential uses, and is already almost compatible with the core API.

You'll need at least PHP 5.6, but head over and see what's changed.

The future...

The adventure doesn't end here! We've got loads of cool stuff planned, including:

  • Monkey patching !!
  • Further compatibility with core reflection
  • Ensuring full PHP 7 compatibility (e.g. with type declarations / return types etc.)
  • getColumn() function(s) to complement getStartLine() and getEndLine()
  • More cool stuff!

Thank you...

It's been quite a journey to get here, and it's been a real challenge to make this work; thanks go to contributors:

Go forth and enjoy the new Roave offering of Better Reflection!