BlueSpice MediaWiki master
 All Classes Namespaces Files Functions Variables Groups Pages
Interwiki Class Reference

Public Member Functions

 __construct ($prefix=null, $url= '', $api= '', $wikiId= '', $local=0, $trans=0)
 
 getURL ($title=null)
 
 getAPI ()
 
 getWikiID ()
 
 isLocal ()
 
 isTranscludable ()
 
 getName ()
 
 getDescription ()
 

Static Public Member Functions

static isValidInterwiki ($prefix)
 
static fetch ($prefix)
 
static invalidateCache ($prefix)
 
static getAllPrefixes ($local=null)
 

Protected Attributes

 $mPrefix
 
 $mURL
 
 $mAPI
 
 $mWikiID
 
 $mLocal
 
 $mTrans
 

Detailed Description

Value object for representing interwiki records.

Member Function Documentation

static Interwiki::fetch (   $prefix)
static

Fetch an Interwiki object

Deprecated:
since 1.28, use InterwikiLookup instead
Parameters
string$prefixInterwiki prefix to use
Returns
Interwiki|null|bool
static Interwiki::getAllPrefixes (   $local = null)
static

Returns all interwiki prefix definitions.

Deprecated:
since 1.28, unused. Use InterwikiLookup instead.
Parameters
string | null$localIf set, limits output to local/non-local interwikis
Returns
array[] List of interwiki rows
Since
1.19
Interwiki::getAPI ( )

Get the API URL for this wiki

Returns
string The URL
Interwiki::getDescription ( )

Get a description for this interwiki

Returns
string
Interwiki::getName ( )

Get the name for the interwiki site

Returns
string
Interwiki::getURL (   $title = null)

Get the URL for a particular title (or with $1 if no title given)

Parameters
string$titleWhat text to put for the article name
Returns
string The URL
Note
Prior to 1.19 The getURL with an argument was broken. If you if you use this arg in an extension that supports MW earlier than 1.19 please wfUrlencode and substitute $1 on your own.
Interwiki::getWikiID ( )

Get the DB name for this wiki

Returns
string The DB name
static Interwiki::invalidateCache (   $prefix)
static

Purge the cache (local and persistent) for an interwiki prefix.

Parameters
string$prefix
Since
1.26
Interwiki::isLocal ( )

Is this a local link from a sister project, or is it something outside, like Google

Returns
bool
Interwiki::isTranscludable ( )

Can pages from this wiki be transcluded? Still requires $wgEnableScaryTransclusion

Returns
bool
static Interwiki::isValidInterwiki (   $prefix)
static

Check whether an interwiki prefix exists

Deprecated:
since 1.28, use InterwikiLookup instead
Parameters
string$prefixInterwiki prefix to use
Returns
bool Whether it exists

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