* zin: add each command to query.

This commit is contained in:
sunhao
2024-02-28 11:28:27 +08:00
parent 59579821f6
commit ea1c5f87ac
+6
View File
@@ -127,6 +127,12 @@ class command
return $node ? $node : array();
}
public static function each(node $node, callable|\Collator $callback)
{
if($callback instanceof \Closure) $callback($node);
else call_user_func($callback, $node);
}
/**
* Magic static method for setting property value.
*