MediaWiki 1.42.1
UploadSourceAdapter Class Reference

This is a horrible hack used to keep source compatibility. More...

Collaboration diagram for UploadSourceAdapter:

Public Member Functions

 stream_eof ()
 
 stream_open ( $path, $mode, $options, &$opened_path)
 
 stream_read ( $count)
 
 stream_tell ()
 
 stream_write ( $data)
 
 url_stat ()
 

Static Public Member Functions

static isSeekableSource (string $id)
 
static registerSource (ImportSource $source)
 
static seekSource (string $id, int $offset)
 

Public Attributes

resource null $context
 Must exists on stream wrapper class.
 

Static Public Attributes

static ImportSource[] $sourceRegistrations = []
 

Detailed Description

This is a horrible hack used to keep source compatibility.

Definition at line 31 of file UploadSourceAdapter.php.

Member Function Documentation

◆ isSeekableSource()

static UploadSourceAdapter::isSeekableSource ( string $id)
static
Parameters
string$id
Returns
bool

Definition at line 63 of file UploadSourceAdapter.php.

◆ registerSource()

static UploadSourceAdapter::registerSource ( ImportSource $source)
static
Parameters
ImportSource$source
Returns
string

Definition at line 51 of file UploadSourceAdapter.php.

References $source, and wfRandomString().

Referenced by WikiImporter\__construct().

◆ seekSource()

static UploadSourceAdapter::seekSource ( string $id,
int $offset )
static
Parameters
string$id
int$offset
Returns
int|false

Definition at line 75 of file UploadSourceAdapter.php.

◆ stream_eof()

UploadSourceAdapter::stream_eof ( )
Returns
bool

Definition at line 153 of file UploadSourceAdapter.php.

◆ stream_open()

UploadSourceAdapter::stream_open ( $path,
$mode,
$options,
& $opened_path )
Parameters
string$path
string$mode
int$options
string&$opened_path
Returns
bool

Definition at line 89 of file UploadSourceAdapter.php.

References $path.

◆ stream_read()

UploadSourceAdapter::stream_read ( $count)
Parameters
int$count
Returns
string

Definition at line 109 of file UploadSourceAdapter.php.

◆ stream_tell()

UploadSourceAdapter::stream_tell ( )
Returns
int

Definition at line 146 of file UploadSourceAdapter.php.

◆ stream_write()

UploadSourceAdapter::stream_write ( $data)
Parameters
string$data
Returns
false

Definition at line 139 of file UploadSourceAdapter.php.

◆ url_stat()

UploadSourceAdapter::url_stat ( )
Returns
int[]

Definition at line 160 of file UploadSourceAdapter.php.

Member Data Documentation

◆ $context

resource null UploadSourceAdapter::$context

Must exists on stream wrapper class.

Definition at line 36 of file UploadSourceAdapter.php.

◆ $sourceRegistrations

ImportSource [] UploadSourceAdapter::$sourceRegistrations = []
static

Definition at line 33 of file UploadSourceAdapter.php.


The documentation for this class was generated from the following file: