public function getTree($asArray = false)
    {
        $return = array();
        if ($asArray && $this->tree) {
            foreach ($this->tree as $file) {
                $return[] = $file->toArray();
            }
        }

        return $asArray ? $return : $this->tree;
    }
public function getTree($asArray = false)
    {
        $return = array();
        if ($asArray && $this->tree) {
            foreach ($this->tree as $file) {
                $return[] = $file->toArray();
            }
        }

        return $asArray ? $return : $this->tree;
    }
public function getTree ( $ asArray = false ) { $ return = array ( ) ; if ( $ asArray && $ this -> tree ) { foreach ( $ this -> tree as $ file ) { $ return [ ] = $ file -> toArray ( ) ; } } return $ asArray ? $ return : $ this -> tree ; }
get Tree.

@param bool $asArray

@return array|FileInfo[]
get Tree .