File.php 447 B

12345678910111213141516171819202122232425
  1. <?php
  2. namespace dokuwiki\Parsing\ParserMode;
  3. class File extends AbstractMode
  4. {
  5. /** @inheritdoc */
  6. public function connectTo($mode)
  7. {
  8. $this->Lexer->addEntryPattern('<file\b(?=.*</file>)', $mode, 'file');
  9. }
  10. /** @inheritdoc */
  11. public function postConnect()
  12. {
  13. $this->Lexer->addExitPattern('</file>', 'file');
  14. }
  15. /** @inheritdoc */
  16. public function getSort()
  17. {
  18. return 210;
  19. }
  20. }