Swat/SwatGroupedFlydown.php
protected function checkTree(SwatTreeFlydownNode $tree, $level = 0)
    {
        if ($level > 2) {
            throw new SwatException(
                'SwatGroupedFlydown tree must not be ' .
                    'more than 3 levels including the root node.'
            );
        }

        foreach ($tree->getChildren() as $child) {
            $this->checkTree($child, $level + 1);
        }
    }
protected function checkTree(SwatTreeFlydownNode $tree, $level = 0)
    {
        if ($level > 2) {
            throw new SwatException(
                'SwatGroupedFlydown tree must not be ' .
                    'more than 3 levels including the root node.'
            );
        }

        foreach ($tree->getChildren() as $child) {
            $this->checkTree($child, $level + 1);
        }
    }
protected function checkTree ( SwatTreeFlydownNode $ tree , $ level = 0 ) { if ( $ level > 2 ) { throw new SwatException ( 'SwatGroupedFlydown tree must not be ' . 'more than 3 levels including the root node.' ) ; } foreach ( $ tree -> getChildren ( ) as $ child ) { $ this -> checkTree ( $ child , $ level + 1 ) ; } }
Checks a tree to ensure it is valid for a grouped flydown

@param SwatTreeFlydownNode the tree to check.

@throws SwatException if the tree is not valid for a grouped flydown.
Checks a tree to ensure it is valid for a grouped flydown