1<?php 2 3namespace dokuwiki\Parsing\ParserMode; 4 5class File extends Code 6{ 7 /** @var string The call type used in addCall ('code' or 'file') */ 8 protected $type = 'file'; 9 10 /** @inheritdoc */ 11 public function getSort() 12 { 13 return 210; 14 } 15 16 /** @inheritdoc */ 17 public function connectTo($mode) 18 { 19 $this->Lexer->addEntryPattern('<file\b(?=.*</file>)', $mode, 'file'); 20 } 21 22 /** @inheritdoc */ 23 public function postConnect() 24 { 25 $this->Lexer->addExitPattern('</file>', 'file'); 26 } 27} 28