ReWriterInterface.php 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. <?php
  2. namespace dokuwiki\Parsing\Handler;
  3. /**
  4. * A ReWriter takes over from the orignal call writer and handles all new calls itself until
  5. * the process method is called and control is given back to the original writer.
  6. *
  7. * @property array[] $calls The list of current calls
  8. */
  9. interface ReWriterInterface extends CallWriterInterface
  10. {
  11. /**
  12. * ReWriterInterface constructor.
  13. *
  14. * This rewriter will be registered as the new call writer in the Handler.
  15. * The original is passed as parameter
  16. *
  17. * @param CallWriterInterface $callWriter the original callwriter
  18. */
  19. public function __construct(CallWriterInterface $callWriter);
  20. /**
  21. * Process any calls that have been added and add them to the
  22. * original call writer
  23. *
  24. * @return CallWriterInterface the orignal call writer
  25. */
  26. public function process();
  27. /**
  28. * Accessor for this rewriter's original CallWriter
  29. *
  30. * @return CallWriterInterface
  31. */
  32. public function getCallWriter();
  33. }