ClassWithSecrets.php 895 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. <?php
  2. /*
  3. * This file is part of Psy Shell.
  4. *
  5. * (c) 2012-2018 Justin Hileman
  6. *
  7. * For the full copyright and license information, please view the LICENSE
  8. * file that was distributed with this source code.
  9. */
  10. namespace Psy\Test;
  11. class ClassWithSecrets
  12. {
  13. private const PRIVATE_CONST = 'private and const';
  14. private static $privateStaticProp = 'private and static and prop';
  15. private $privateProp = 'private and prop';
  16. private static function privateStaticMethod($extra = null)
  17. {
  18. if ($extra !== null) {
  19. return 'private and static and method with ' . \json_encode($extra);
  20. }
  21. return 'private and static and method';
  22. }
  23. private function privateMethod($extra = null)
  24. {
  25. if ($extra !== null) {
  26. return 'private and method with ' . \json_encode($extra);
  27. }
  28. return 'private and method';
  29. }
  30. }