public static function register($protocol = 'gridfs', $force = false)
    {
        if (in_array($protocol, stream_get_wrappers())) {
            if (!$force) {
                return;
            }
            stream_wrapper_unregister($protocol);
        }

        stream_wrapper_register($protocol, get_called_class(), STREAM_IS_URL);
    }
public static function register($protocol = 'gridfs', $force = false)
    {
        if (in_array($protocol, stream_get_wrappers())) {
            if (!$force) {
                return;
            }
            stream_wrapper_unregister($protocol);
        }

        stream_wrapper_register($protocol, get_called_class(), STREAM_IS_URL);
    }
public static function register ( $ protocol = 'gridfs' , $ force = false ) { if ( in_array ( $ protocol , stream_get_wrappers ( ) ) ) { if ( ! $ force ) { return ; } stream_wrapper_unregister ( $ protocol ) ; } stream_wrapper_register ( $ protocol , get_called_class ( ) , STREAM_IS_URL ) ; }
Registers this steam wrapper.
@param string $protocol name of the protocol to be used.
@param bool $force whether to register wrapper, even if protocol is already taken.
Registers this steam wrapper .