public function ParsedMarkdown::matches in Markdown 8.2
Compares whether the provided markdown matches this object.
Parameters
string|\Drupal\markdown\Render\ParsedMarkdownInterface $markdown: An external markdown source.
Return value
bool TRUE or FALSE
Overrides ParsedMarkdownInterface::matches
File
- src/
Render/ ParsedMarkdown.php, line 168
Class
- ParsedMarkdown
- The end result of parsing markdown into HTML.
Namespace
Drupal\markdown\RenderCode
public function matches($markdown) {
if ($markdown instanceof static) {
return $markdown
->getMarkdown() === $this
->getMarkdown();
}
return static::normalizeMarkdown($markdown) === $this
->getMarkdown();
}