function FrontMatter::getLine
Same name in other branches
- 9 core/lib/Drupal/Component/FrontMatter/FrontMatter.php \Drupal\Component\FrontMatter\FrontMatter::getLine()
- 10 core/lib/Drupal/Component/FrontMatter/FrontMatter.php \Drupal\Component\FrontMatter\FrontMatter::getLine()
- 11.x core/lib/Drupal/Component/FrontMatter/FrontMatter.php \Drupal\Component\FrontMatter\FrontMatter::getLine()
Retrieves the line where the source code starts, after any data.
Return value
int The source code line.
Throws
\Drupal\Component\Serialization\Exception\InvalidDataTypeException Exception thrown when the Front Matter cannot be parsed.
File
-
core/
modules/ help_topics/ src/ FrontMatter.php, line 169
Class
- FrontMatter
- Extracts Front Matter from the beginning of a source.
Namespace
Drupal\help_topicsCode
public function getLine() {
return $this->parse()['line'];
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.