public function findNode(string $name): ?Node
    {
        foreach ($this->nodes as $node) {
            if ($node instanceof self && !empty($node->name)) {
                if ($node->name === $name) {
                    return $node;
                }

                if ($found = $node->findNode($name)) {
                    return $found;
                }
            }
        }

        return null;
    }
public function findNode(string $name): ?Node
    {
        foreach ($this->nodes as $node) {
            if ($node instanceof self && !empty($node->name)) {
                if ($node->name === $name) {
                    return $node;
                }

                if ($found = $node->findNode($name)) {
                    return $found;
                }
            }
        }

        return null;
    }
public function findNode ( string $ name ) : ? Node { foreach ( $ this -> nodes as $ node ) { if ( $ node instanceof self && ! empty ( $ node -> name ) ) { if ( $ node -> name === $ name ) { return $ node ; } if ( $ found = $ node -> findNode ( $ name ) ) { return $ found ; } } } return null ; }
Recursively find a children node by it's name.

@param string $name
@return Node|null
Recursively find a children node by it s name .