Php/docs/commonmark-cql.invoke

提供:Dev Guides
< Php
2020年12月14日 (月) 12:40時点におけるNotes (トーク | 投稿記録)による版 (autoload)
(差分) ← 古い版 | 最新版 (差分) | 新しい版 → (差分)
移動先:案内検索

CommonMark\CQL::__invoke

(cmark >= 1.1.0)

CommonMark\CQL::__invokeCQL Execution


説明

public CommonMark\CQL::__invoke ( CommonMark\Node $root , callable $handler )

Shall invoke the current CQL function on the given root, executing the given handler on entry to a CommonMark\Node


パラメータ

root

the root node of a tree

handler

should have the prototype:

handler ( CommonMark\Node $root , CommonMark\Node $entering ) : bool|null

  • Should handler fail to return (void), or return null, CQL will continue executing
  • Should the handler return a truthy value, CQL will continue executing.
  • Should the handler return a falsy value, CQL will stop executing