MediaWiki
1.34.0
ExternalStoreHttp.php
Go to the documentation of this file.
1
<?php
23
use
MediaWiki\MediaWikiServices
;
24
31
class
ExternalStoreHttp
extends
ExternalStoreMedium
{
32
public
function
fetchFromURL
( $url ) {
33
return
MediaWikiServices::getInstance()->getHttpRequestFactory()->
34
get
( $url, [], __METHOD__ );
35
}
36
37
public
function
store
( $location, $data ) {
38
throw
new
MWException
(
"ExternalStoreHttp is read-only and does not support store()."
);
39
}
40
41
public
function
isReadOnly
( $location ) {
42
return
true
;
43
}
44
}
ExternalStoreMedium
Key/value blob storage for a particular storage medium type (e.g.
Definition:
ExternalStoreMedium.php:38
MediaWiki\MediaWikiServices
MediaWikiServices is the service locator for the application scope of MediaWiki.
Definition:
MediaWikiServices.php:117
ExternalStoreHttp\store
store( $location, $data)
Insert a data item into a given location.
Definition:
ExternalStoreHttp.php:37
MWException
MediaWiki exception.
Definition:
MWException.php:26
ExternalStoreHttp\fetchFromURL
fetchFromURL( $url)
Fetch data from given external store URL.
Definition:
ExternalStoreHttp.php:32
ExternalStoreHttp\isReadOnly
isReadOnly( $location)
Check if a given location is read-only.
Definition:
ExternalStoreHttp.php:41
ExternalStoreHttp
Example class for HTTP accessible external objects.
Definition:
ExternalStoreHttp.php:31
includes
externalstore
ExternalStoreHttp.php
Generated on Thu Dec 19 2019 14:54:18 for MediaWiki by
1.8.16