polass / exposer
Exposer exposes hidden properties and methods
v1.0.1
2017-06-13 14:56 UTC
Requires
- php: >=5.6.0
Requires (Dev)
- phpunit/phpunit: ~5.7
This package is not auto-updated.
Last update: 2024-11-24 03:45:42 UTC
README
The Exposer exposes hidden properties and methods.
Usage
<?php class Secrecy { private $property = 'hidden'; private function method($argument) { return 'called'; } } $exposer = expose(new Secrecy); echo $exposer->property; // `hidden` $exposer->property = 'exposed'; echo $exposer->property; // `exposed` echo $exposer->method('argument'); // `called`