N98\Magento\Command\System\Setup\RunCommand::flushCache PHP Метод

flushCache() приватный Метод

private flushCache ( )
    private function flushCache()
    {
        /**
         * Get events before cache flush command is called.
         */
        $reflectionApp = new \ReflectionObject(\Mage::app());
        $appEventReflectionProperty = $reflectionApp->getProperty('_events');
        $appEventReflectionProperty->setAccessible(true);
        $eventsBeforeCacheFlush = $appEventReflectionProperty->getValue(\Mage::app());
        $this->getApplication()->run(new StringInput('cache:flush'), new NullOutput());
        /**
         * Restore initially loaded events which was reset during setup script run
         */
        $appEventReflectionProperty->setValue(\Mage::app(), $eventsBeforeCacheFlush);
    }