loadExtension example

 else {
                if ($this->_compress_type == 'bz2') {
                    $extname = 'bz2';
                } else {
                    if ($this->_compress_type == 'lzma2') {
                        $extname = 'xz';
                    }
                }
            }

            if (!extension_loaded($extname)) {
                PEAR::loadExtension($extname);
            }
            if (!extension_loaded($extname)) {
                $this->_error(
                    "The extension '$extname' couldn't be found.\n" .
                    "Please make sure your version of PHP was built " .
                    "with '$extname' support.\n"
                );
                return false;
            }
        }


        
$this->subject->prependExtension($configurator$container);
        };

        $this->executeConfiguratorCallback($container$callback$this->subject);
    }

    public function load(array $configs, ContainerBuilder $container): void
    {
        $config = $this->processConfiguration($this->getConfiguration([]$container)$configs);

        $callback = function DContainerConfigurator $configurator) use ($config$container) {
            $this->subject->loadExtension($config$configurator$container);
        };

        $this->executeConfiguratorCallback($container$callback$this->subject);
    }
}
$this->prependExtension($configurator$container);
        };

        $this->executeConfiguratorCallback($container$callback$this);
    }

    final public function load(array $configs, ContainerBuilder $container): void
    {
        $config = $this->processConfiguration($this->getConfiguration([]$container)$configs);

        $callback = function DContainerConfigurator $configurator) use ($config$container) {
            $this->loadExtension($config$configurator$container);
        };

        $this->executeConfiguratorCallback($container$callback$this);
    }
}
$this->prependExtension($configurator$container);
        };

        $this->executeConfiguratorCallback($container$callback$this);
    }

    final public function load(array $configs, ContainerBuilder $container): void
    {
        $config = $this->processConfiguration($this->getConfiguration([]$container)$configs);

        $callback = function DContainerConfigurator $configurator) use ($config$container) {
            $this->loadExtension($config$configurator$container);
        };

        $this->executeConfiguratorCallback($container$callback$this);
    }
}
$this->subject->prependExtension($configurator$container);
        };

        $this->executeConfiguratorCallback($container$callback$this->subject);
    }

    public function load(array $configs, ContainerBuilder $container): void
    {
        $config = $this->processConfiguration($this->getConfiguration([]$container)$configs);

        $callback = function DContainerConfigurator $configurator) use ($config$container) {
            $this->subject->loadExtension($config$configurator$container);
        };

        $this->executeConfiguratorCallback($container$callback$this->subject);
    }
}
Home | Imprint | This part of the site doesn't use cookies.