protected function getVariables($showAll)
    {
        $scopeVars = $this->context->getAll();
        \uksort($scopeVars, function ($a, $b) {
            $aIndex = \array_search($a, self::$specialNames);
            $bIndex = \array_search($b, self::$specialNames);

            if ($aIndex !== false) {
                if ($bIndex !== false) {
                    return $aIndex - $bIndex;
                }

                return 1;
            }

            if ($bIndex !== false) {
                return -1;
            }

            return \strnatcasecmp($a, $b);
        });

        $ret = [];
        foreach ($scopeVars as $name => $val) {
            if (!$showAll && \in_array($name, self::$specialNames)) {
                continue;
            }

            $ret[$name] = $val;
        }

        return $ret;
    }
protected function getVariables($showAll)
    {
        $scopeVars = $this->context->getAll();
        \uksort($scopeVars, function ($a, $b) {
            $aIndex = \array_search($a, self::$specialNames);
            $bIndex = \array_search($b, self::$specialNames);

            if ($aIndex !== false) {
                if ($bIndex !== false) {
                    return $aIndex - $bIndex;
                }

                return 1;
            }

            if ($bIndex !== false) {
                return -1;
            }

            return \strnatcasecmp($a, $b);
        });

        $ret = [];
        foreach ($scopeVars as $name => $val) {
            if (!$showAll && \in_array($name, self::$specialNames)) {
                continue;
            }

            $ret[$name] = $val;
        }

        return $ret;
    }
protected function getVariables ( $ showAll ) { $ scopeVars = $ this -> context -> getAll ( ) ; \ uksort ( $ scopeVars , function ( $ a , $ b ) { $ aIndex = \ array_search ( $ a , self :: $ specialNames ) ; $ bIndex = \ array_search ( $ b , self :: $ specialNames ) ; if ( $ aIndex !== false ) { if ( $ bIndex !== false ) { return $ aIndex - $ bIndex ; } return 1 ; } if ( $ bIndex !== false ) { return - 1 ; } return \ strnatcasecmp ( $ a , $ b ) ; } ) ; $ ret = [ ] ; foreach ( $ scopeVars as $ name => $ val ) { if ( ! $ showAll && \ in_array ( $ name , self :: $ specialNames ) ) { continue ; } $ ret [ $ name ] = $ val ; } return $ ret ; }
Get scope variables.

@param bool $showAll Include special variables (e.g. $_)

@return array
Get scope variables .