WordPress как на ладони
Недорогой хостинг для сайтов на WordPress: wordpress.jino.ru Платформа для конвертации и монетизации трафика
функция не описана


AutoloadGenerator::dump() public WC 1.0

Dump the Jetpack autoloader files.

{} Это метод класса: AutoloadGenerator{}

Хуков нет.


Null. Ничего.


$AutoloadGenerator = new AutoloadGenerator();

Код AutoloadGenerator::dump() WC 5.0.0

public function dump(
	Composer $composer,
	Config $config,
	InstalledRepositoryInterface $localRepo,
	PackageInterface $mainPackage,
	InstallationManager $installationManager,
	$scanPsrPackages = false,
	$suffix = null
) {
	$this->filesystem->ensureDirectoryExists( $config->get( 'vendor-dir' ) );

	$packageMap = $composer->getAutoloadGenerator()->buildPackageMap( $installationManager, $mainPackage, $localRepo->getCanonicalPackages() );
	$autoloads  = $this->parseAutoloads( $packageMap, $mainPackage );

	// Convert the autoloads into a format that the manifest generator can consume more easily.
	$basePath           = $this->filesystem->normalizePath( realpath( getcwd() ) );
	$vendorPath         = $this->filesystem->normalizePath( realpath( $config->get( 'vendor-dir' ) ) );
	$processedAutoloads = $this->processAutoloads( $autoloads, $scanPsrPackages, $vendorPath, $basePath );
	unset( $packageMap, $autoloads );

	// Make sure none of the legacy files remain that can lead to problems with the autoloader.
	$this->removeLegacyFiles( $vendorPath );

	// Write all of the files now that we're done.
	$this->writeAutoloaderFiles( $vendorPath . '/jetpack-autoloader/', $suffix );
	$this->writeManifests( $vendorPath . '/' . $targetDir, $processedAutoloads );

	if ( ! $scanPsrPackages ) {
		$this->io->writeError( '<warning>You are generating an unoptimized autoloader. If this is a production build, consider using the -o option.</warning>' );