TestObjectWithToString.php 350 B

1234567891011121314151617181920
  1. <?php
  2. declare(strict_types=1);
  3. namespace TestApp\View\Object;
  4. /**
  5. * TestObjectWithToString
  6. *
  7. * An object with the magic method __toString() for testing with view blocks.
  8. */
  9. class TestObjectWithToString
  10. {
  11. /**
  12. * Return string value.
  13. */
  14. public function __toString(): string
  15. {
  16. return "I'm ObjectWithToString";
  17. }
  18. }