CompilerInterface.php 963 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. namespace Magento\Framework\View\TemplateEngine\Xhtml;
  7. use Magento\Framework\DataObject;
  8. /**
  9. * Interface CompilerInterface
  10. *
  11. * @api
  12. * @since 100.0.2
  13. */
  14. interface CompilerInterface
  15. {
  16. const PATTERN_TAG = '|@|';
  17. /**
  18. * The compilation of the template and filling in the data
  19. *
  20. * @param \DOMNode $node
  21. * @param Object $dataObject
  22. * @param Object $context
  23. * @return void
  24. */
  25. public function compile(\DOMNode $node, DataObject $dataObject, DataObject $context);
  26. /**
  27. * Run postprocessing contents
  28. *
  29. * @param string $content
  30. * @return string
  31. */
  32. public function postprocessing($content);
  33. /**
  34. * Set postprocessing data
  35. *
  36. * @param string $key
  37. * @param string $content
  38. * @return void
  39. */
  40. public function setPostprocessingData($key, $content);
  41. }