public static function checkAutoloadDump(\Composer\Composer $composer)
    {
        if (static::$useAutoloadDump === null) {
            static::$useAutoloadDump = false;

            $rootPackage = static::getRootPackage($composer);
            if (!$rootPackage || ($rootPackage->getType() !== 'project')) {
                return false;
            }

            $rootPackageRequires = $rootPackage->getRequires();
            if (!isset($rootPackageRequires[static::PACKAGE_NAME])) {
                return false;
            }

            $scripts = $rootPackage->getScripts();
            $callback = get_called_class() . '::postAutoloadDump';
            if (!isset($scripts['post-autoload-dump']) || !in_array($callback, $scripts['post-autoload-dump'])) {
                return false;
            }

            static::$useAutoloadDump = true;
        }

        return static::$useAutoloadDump;
    }
public static function checkAutoloadDump(\Composer\Composer $composer)
    {
        if (static::$useAutoloadDump === null) {
            static::$useAutoloadDump = false;

            $rootPackage = static::getRootPackage($composer);
            if (!$rootPackage || ($rootPackage->getType() !== 'project')) {
                return false;
            }

            $rootPackageRequires = $rootPackage->getRequires();
            if (!isset($rootPackageRequires[static::PACKAGE_NAME])) {
                return false;
            }

            $scripts = $rootPackage->getScripts();
            $callback = get_called_class() . '::postAutoloadDump';
            if (!isset($scripts['post-autoload-dump']) || !in_array($callback, $scripts['post-autoload-dump'])) {
                return false;
            }

            static::$useAutoloadDump = true;
        }

        return static::$useAutoloadDump;
    }
public static function checkAutoloadDump ( \ Composer \ Composer $ composer ) { if ( static :: $ useAutoloadDump === null ) { static :: $ useAutoloadDump = false ; $ rootPackage = static :: getRootPackage ( $ composer ) ; if ( ! $ rootPackage || ( $ rootPackage -> getType ( ) !== 'project' ) ) { return false ; } $ rootPackageRequires = $ rootPackage -> getRequires ( ) ; if ( ! isset ( $ rootPackageRequires [ static :: PACKAGE_NAME ] ) ) { return false ; } $ scripts = $ rootPackage -> getScripts ( ) ; $ callback = get_called_class ( ) . '::postAutoloadDump' ; if ( ! isset ( $ scripts [ 'post-autoload-dump' ] ) || ! in_array ( $ callback , $ scripts [ 'post-autoload-dump' ] ) ) { return false ; } static :: $ useAutoloadDump = true ; } return static :: $ useAutoloadDump ; }
Checks whether the autoload dump event is used

Using the autoload dump event is synonymous with creating the
`pico-plugin.php` in Composer's vendor dir. Plugins are nevertheless
installed to Pico's `plugins/` dir ({@see static::getInstallPath()}).

The autoload dump event is used when the root package is a project and
explicitly requires this composer installer.

@param  \Composer\Composer $composer
@return bool
Checks whether the autoload dump event is used