Exakat\Analyzer\Structures\VardumpUsage::analyze PHP Метод

analyze() публичный Метод

public analyze ( )
    public function analyze()
    {
        $debug_functions = array('var_dump', 'print_r', 'var_export');
        // print_r (but not print_r($a, 1))
        $this->atomFunctionIs(array('\\print_r', '\\var_export'))->outIs('ARGUMENTS')->outWithRank('ARGUMENT', 1)->analyzerIsNot('Structures/Truthy')->back('first');
        $this->prepareQuery();
        $this->atomFunctionIs('\\var_dump')->back('first');
        $this->prepareQuery();
        // (well, we need to check if the result string is not printed now...)
        $this->atomIs('Functioncall')->functioncallIs(array('\\var_export', '\\print_r'))->outIs('ARGUMENTS')->noChildWithRank('ARGUMENT', 1)->back('first');
        $this->prepareQuery();
        // echo '<pre>'.print_r($a, 1);
        $this->atomIs('Functioncall')->tokenIs(array('T_ECHO', 'T_PRINT'))->outIs('ARGUMENTS')->atomInside('Functioncall')->functioncallIs(array('\\var_export', '\\print_r'))->outIs('ARGUMENTS')->back('first');
        $this->prepareQuery();
        //         call_user_func_array('var_dump', )
        $this->atomIs('Functioncall')->hasNoIn('METHOD')->tokenIs(array('T_STRING', 'T_NS_SEPARATOR'))->functioncallIs(array('\\call_user_func_array', '\\call_user_func'))->outIs('ARGUMENTS')->outIs('ARGUMENT')->is('rank', 0)->atomIs('String')->tokenIsNot('T_QUOTE')->noDelimiterIs($debug_functions)->back('first');
        $this->prepareQuery();
    }