The class named has to define appropriate methods if it wants to have this functionality: __get(), __set() and __call() respectively for getting / setting a property, or calling a method.
This extension is EXPERIMENTAL. The behaviour of this extension -- including the names of its functions and anything else documented about this extension -- may change without notice in a future release of PHP. Use this extension at your own risk.