public static function register($protocol, FilesystemInterface $filesystem, array $configuration = null, $flags = 0)
    {
        if (static::streamWrapperExists($protocol)) {
            return false;
        }

        static::$config[$protocol] = $configuration ?: static::$defaultConfiguration;
        static::registerPlugins($protocol, $filesystem);
        static::$filesystems[$protocol] = $filesystem;

        return stream_wrapper_register($protocol, __CLASS__, $flags);
    }
public static function register($protocol, FilesystemInterface $filesystem, array $configuration = null, $flags = 0)
    {
        if (static::streamWrapperExists($protocol)) {
            return false;
        }

        static::$config[$protocol] = $configuration ?: static::$defaultConfiguration;
        static::registerPlugins($protocol, $filesystem);
        static::$filesystems[$protocol] = $filesystem;

        return stream_wrapper_register($protocol, __CLASS__, $flags);
    }
public static function register ( $ protocol , FilesystemInterface $ filesystem , array $ configuration = null , $ flags = 0 ) { if ( static :: streamWrapperExists ( $ protocol ) ) { return false ; } static :: $ config [ $ protocol ] = $ configuration ? : static :: $ defaultConfiguration ; static :: registerPlugins ( $ protocol , $ filesystem ) ; static :: $ filesystems [ $ protocol ] = $ filesystem ; return stream_wrapper_register ( $ protocol , __CLASS__ , $ flags ) ; }
Registers the stream wrapper protocol if not already registered.

@param string              $protocol      The protocol.
@param FilesystemInterface $filesystem    The filesystem.
@param array|null          $configuration Optional configuration.
@param int                 $flags         Should be set to STREAM_IS_URL if protocol is a URL protocol. Default is 0, local stream.

@return bool True if the protocol was registered, false if not.
Registers the stream wrapper protocol if not already registered .