Language Class Reference
[Language]

Internationalisation code. More...

Inherited by LanguageAm, LanguageAr, LanguageAz, LanguageBe, LanguageBe_tarask, LanguageBg, LanguageBh, LanguageBs, LanguageCs, LanguageCu, LanguageCy, LanguageDsb, LanguageEo, LanguageEt, LanguageFi, LanguageFr, LanguageGa, LanguageGd, LanguageGv, LanguageHe, LanguageHi, LanguageHr, LanguageHsb, LanguageHu, LanguageHy, LanguageIu, LanguageJa, LanguageKaa, LanguageKk_cyrl, LanguageKm, LanguageKsh, LanguageKu_ku, LanguageLa, LanguageLn, LanguageLt, LanguageLv, LanguageMg, LanguageMk, LanguageMl, LanguageMo, LanguageMt, LanguageMy, LanguageNso, LanguageOs, LanguagePl, LanguageQqx, LanguageRo, LanguageRu, LanguageSe, LanguageSgs, LanguageSh, LanguageShi, LanguageSk, LanguageSl, LanguageSma, LanguageSr_ec, LanguageSr_el, LanguageTg, LanguageTi, LanguageTl, LanguageToTest, LanguageTr, LanguageTyv, LanguageUk, LanguageWa, LanguageYue, and LanguageZh_hans.

List of all members.

Public Member Functions

 __construct ()
 __destruct ()
 Reduce memory usage.
 addMagicWordsByLang ($newWords)
 Add magic words to the extension array.
 alignEnd ()
 Return 'right' or 'left' as appropriate alignment for line-end for this language's text direction.
 alignStart ()
 Return 'left' or 'right' as appropriate alignment for line-start for this language's text direction.
 armourMath ($text)
 Put custom tags (e.g.
 autoConvertToAllVariants ($text)
 convert text to all supported variants
 capitalizeAllNouns ()
 caseFold ($s)
 Return a case-folded representation of $s.
 checkTitleEncoding ($s)
 commafy ($_)
 Adds commas to a given number.
 commaList (array $list)
 Take a list of strings and build a locale-friendly comma-separated list, using the local comma-separator message.
 convert ($text)
 convert text to different variants of a language.
 convertCategoryKey ($key)
 convertForSearchResult ($termsArray)
 convertGrammar ($word, $case)
 Grammatical transformations, needed for inflected languages Invoked by putting {{grammar:case|word}} in a message.
 convertHtml ($text, $isTitle=false)
 Perform output conversion on a string, and encode for safe HTML output.
 convertLinkToAllVariants ($text)
 If a language supports multiple variants, converts text into an array of all possible variants of the text: 'variant' => text in that variant.
 convertPlural ($count, $forms)
 Plural form transformations, needed for some languages.
 convertTitle ($title)
 Convert a Title object to a string in the preferred variant.
 date ($ts, $adj=false, $format=true, $timecorrection=false)
 dateFormat ($usePrefs=true)
 This is meant to be used by time(), date(), and timeanddate() to get the date preference they're supposed to use, it should be used in all children.
 digitGroupingPattern ()
 digitTransformTable ()
 emphasize ($text)
 Italic is unsuitable for some languages.
 fallback8bitEncoding ()
 findVariantLink (&$link, &$nt, $ignoreOtherCond=false)
 If a language supports multiple variants, it is possible that non-existing link in one variant actually exists in another variant.
 firstChar ($s)
 Get the first character of a string.
 fixVariableInNamespace ($talk)
 formatBitrate ($bps)
 Format a bitrate for output, using an appropriate unit (bps, kbps, Mbps, Gbps, Tbps, Pbps, Ebps, Zbps or Ybps) according to the magnitude in question.
 formatComputingNumbers ($size, $boundary, $messageKey)
 formatDuration ($seconds, array $chosenIntervals=array())
 Takes a number of seconds and turns it into a text using values such as hours and minutes.
 formatExpiry ($expiry, $format=true)
 Decode an expiry (block, protection, etc) which has come from the DB.
 formatNum ($number, $nocommafy=false)
 Normally we output all numbers in plain en_US style, that is 293,291.235 for twohundredninetythreethousand-twohundredninetyone point twohundredthirtyfive.
 formatSize ($size)
 Format a size in bytes for output, using an appropriate unit (B, KB, MB, GB, TB, PB, EB, ZB or YB) according to the magnitude in question.
 formatTimePeriod ($seconds, $format=array())
 gender ($gender, $forms)
 Provides an alternative text depending on specified gender.
 getAllMessages ()
 getArrow ()
 An arrow, depending on the language direction.
 getBookstoreList ()
 Exports $wgBookstoreListEn.
 getCode ()
 Get the RFC 3066 code for this language object.
 getConverter ()
 Return the LanguageConverter used in the Language.
 getConvRuleTitle ()
 Get the conversion rule title, if any.
 getDateFormats ()
 getDateFormatString ($type, $pref)
 Get a format string for a given type and preference.
 getDatePreferenceMigrationMap ()
 getDatePreferences ()
 getDefaultDateFormat ()
 getDefaultVariant ()
 getDir ()
 Return the correct HTML 'dir' attribute value for this language.
 getDirMark ($opposite=false)
 A hidden direction mark (LRM or RLM), depending on the language direction.
 getDirMarkEntity ($opposite=false)
 A hidden direction mark (LRM or RLM), depending on the language direction.
 getDurationIntervals ($seconds, array $chosenIntervals=array())
 Takes a number of seconds and returns an array with a set of corresponding intervals.
 getExtraHashOptions ()
 returns language specific options used by User::getPageRenderHash() for example, the preferred language variant
 getExtraUserToggles ()
 getFallbackLanguageCode ()
 Same as getFallbacksFor for current language.
 getFallbackLanguages ()
 getFormattedNamespaces ()
 A convenience function that returns the same thing as getNamespaces() except with the array values changed to ' ' where it found '_', useful for producing output to be displayed e.g.
 getFormattedNsText ($index)
 A convenience function that returns the same thing as getNsText() except with '_' changed to ' ', useful for producing output.
 getGenderNsText ($index, $gender)
 Returns gender-dependent namespace alias if available.
 getGrammarForms ()
 Get the grammar forms for the content language.
 getHebrewCalendarMonthName ($key)
 getHebrewCalendarMonthNameGen ($key)
 getHijriCalendarMonthName ($key)
 getHtmlCode ()
 Get the code in Bcp47 format which we can use inside of html lang="" tags.
 getImageFile ($image)
 getIranianCalendarMonthName ($key)
 getLangObj ()
 getLanguageName ($code)
 Get the native language name of $code.
 getLocalNsIndex ($text)
 Get a namespace key by value, case insensitive.
 getMagic ($mw)
 Fill a MagicWord object with data from here.
 getMagicWords ()
 getMessage ($key)
 getMessageFromDB ($msg)
 Get a message from the MediaWiki namespace.
 getMonthAbbreviation ($key)
 getMonthAbbreviationsArray ()
 getMonthName ($key)
 getMonthNameGen ($key)
 getMonthNamesArray ()
 getNamespaceAliases ()
 getNamespaceIds ()
 getNamespaces ()
 getNsIndex ($text)
 Get a namespace key by value, case insensitive.
 getNsText ($index)
 Get a namespace value by key $mw_ns = $wgContLang->getNsText( NS_MEDIAWIKI ); echo $mw_ns; // prints 'MediaWiki'
 getParsedTitle ()
 For languages that support multiple variants, the title of an article may be displayed differently in different variants.
 getPreferredVariant ()
 getQuickbarSettings ()
 getSpecialPageAliases ()
 Get special page names, as an associative array case folded alias => real name.
 getURLVariant ()
 getUserToggle ($tog)
 getVariantname ($code, $usemsg=true)
 short names for language variants used for language conversion links.
 getVariants ()
 Get the list of variants supported by this language see sample implementation in LanguageZh.php.
 getWeekdayAbbreviation ($key)
 getWeekdayName ($key)
 hasVariant ($variant)
 Check if the language has the specific variant.
 hasVariants ()
 Check if this is a language with variants.
 hasWordBreaks ()
 Most writing systems use whitespace to break up words.
 iconv ($in, $out, $string)
 initContLang ()
 Hook which will be called if this is the content language.
 initEncoding ()
 isMultibyte ($str)
 isRTL ()
 For right-to-left language support.
 lc ($str, $first=false)
 lcCallback ($matches)
 lcfirst ($str)
 linkPrefixExtension ()
 To allow "foo[[bar]]" to extend the link over the whole word "foobar".
 linkTrail ()
 A regular expression to match legal word-trailing characters which should be merged onto a link of the form [[foo]]bar.
 listToText (array $l)
 Take a list of strings and build a locale-friendly comma-separated list, using the local comma-separator message.
 markNoConversion ($text, $noParse=false)
 Enclose a string with the "no conversion" tag.
 needsGenderDistinction ()
 Whether this language makes distinguishes genders for example in namespaces.
 normalize ($s)
 Convert a UTF-8 string to normal form C.
 normalizeForSearch ($string)
 Some languages have special punctuation need to be normalized.
 parseFormattedNumber ($number)
 pipeList (array $list)
 Same as commaList, but separate it with the pipe instead.
 recodeForEdit ($s)
 recodeInput ($s)
 replaceGrammarInNamespace ($m)
 segmentByWord ($string)
 Some languages such as Chinese require word segmentation, Specify such segmentation when overridden in derived class.
 segmentForDiff ($text)
 languages like Chinese need to be segmented in order for the diff to be of any use
 semicolonList (array $list)
 Take a list of strings and build a locale-friendly semicolon-separated list, using the local semicolon-separator message.
 separatorTransformTable ()
 setCode ($code)
 setNamespaces (array $namespaces)
 Arbitrarily set all of the namespace names at once.
 specialList ($page, $details, $oppositedm=true)
 Make a list item, used by various special pages.
 specialPage ($name)
 sprintfDate ($format, $ts)
 This is a workalike of PHP's date() function, but with better internationalisation, a reduced set of format characters, and a better escaping format.
 time ($ts, $adj=false, $format=true, $timecorrection=false)
 timeanddate ($ts, $adj=false, $format=true, $timecorrection=false)
 transformUsingPairFile ($file, $string)
 Transform a string using serialized data stored in the given file (which must be in the serialized subdirectory of $IP).
 translateBlockExpiry ($str)
 truncate ($string, $length, $ellipsis= '...', $adjustLength=true)
 Truncate a string to a specified length in bytes, appending an optional string (e.g.
 truncateHtml ($text, $length, $ellipsis= '...')
 Truncate a string of valid HTML to a specified length in bytes, appending an optional string (e.g.
 uc ($str, $first=false)
 Convert a string to uppercase.
 ucCallback ($matches)
 ucfirst ($str)
 Make a string's first character uppercase.
 ucwordbreaks ($str)
 capitalize words at word breaks
 ucwordbreaksCallbackAscii ($matches)
 ucwordbreaksCallbackMB ($matches)
 ucwords ($str)
 ucwordsCallbackMB ($matches)
 ucwordsCallbackWiki ($matches)
 unsegmentForDiff ($text)
 and unsegment to show the result
 userAdjust ($ts, $tz=false)
 Used by date() and time() to adjust the time output.
 userDate ($ts, User $user, array $options=array())
 Get the formatted date for the given timestamp and formatted for the given user.
 userTime ($ts, User $user, array $options=array())
 Get the formatted time for the given timestamp and formatted for the given user.
 userTimeAndDate ($ts, User $user, array $options=array())
 Get the formatted date and time for the given timestamp and formatted for the given user.
 viewPrevNext (Title $title, $offset, $limit, array $query=array(), $atend=false)
 Generate (prev x| next x) (20|50|100.

Static Public Member Functions

static classFromCode ($code)
static factory ($code)
 Get a cached language object for a given language code.
static fetchLanguageName ($code, $inLanguage=null, $include= 'all')
static fetchLanguageNames ($inLanguage=null, $include= 'mw')
 Get an array of language names, indexed by code.
static getCaseMaps ()
static getClassFileName ($code)
static getCodeFromFileName ($filename, $prefix= 'Language', $suffix= '.php')
 Get the language code from a file name.
static getFallbackFor ($code)
 Get the first fallback for a given language.
static getFallbacksFor ($code)
 Get the ordered list of fallback languages.
static getFileName ($prefix= 'Language', $code, $suffix= '.php')
 Get the name of a file for a certain language code.
static getLanguageNames ($customisedOnly=false)
 Get native language names, indexed by code.
static getLocalisationCache ()
 Get the LocalisationCache instance.
static getMessageFor ($key, $code)
 Get a message for a given language.
static getMessageKeysFor ($code)
 Get all message keys for a given language.
static getMessagesFileName ($code)
static getMessagesFor ($code)
 Get all messages for a given language WARNING: this may take a long time.
static getTranslatedLanguageNames ($code)
 Get translated language names.
static hebrewNumeral ($num)
 Hebrew Gematria number formatting up to 9999.
static isValidBuiltInCode ($code)
 Returns true if a language code is of a valid form for the purposes of internal customisation of MediaWiki, via Messages*.php.
static isValidCode ($code)
 Returns true if a language code string is of a valid form, whether or not it exists.
static preloadLanguageClass ($class)
 Includes language class files.
static romanNumeral ($num)
 Roman number formatting up to 3000.

Public Attributes

 $dateFormatStrings = array()
 $mCode
 $mConverter
 $mExtendedSpecialPageAliases
 $mLoaded = false
 $mMagicExtensions = array()
 $mMagicHookDone = false
 $mVariants
 $transformData = array()
 ReplacementArray object caches.

Static Public Attributes

static $dataCache
static $durationIntervals
static $mHebrewCalendarMonthGenMsgs
static $mHebrewCalendarMonthMsgs
static $mHijriCalendarMonthMsgs
static $mIranianCalendarMonthMsgs
static $mLangObjCache = array()
static $mMonthAbbrevMsgs
static $mMonthGenMsgs
static $mMonthMsgs
static $mWeekdayAbbrevMsgs
static $mWeekdayMsgs

Protected Member Functions

 doMagicHook ()
 preConvertPlural ($forms, $count)
 Checks that convertPlural was given an array and pads it to requested amount of forms by copying the last one.
 removeBadCharFirst ($string)
 Remove bytes that represent an incomplete Unicode character at the start of string (e.g.
 removeBadCharLast ($string)
 Remove bytes that represent an incomplete Unicode character at the end of string (e.g.

Static Protected Member Functions

static convertDoubleWidth ($string)
 convert double-width roman characters to single-width.
static insertSpace ($string, $pattern)
static newFromCode ($code)
 Create a language object for a given language code.

Protected Attributes

 $mNamespaceIds
 $namespaceAliases
 $namespaceNames

Private Member Functions

 internalUserTimeAndDate ($type, $ts, User $user, array $options)
 Internal helper function for userDate(), userTime() and userTimeAndDate().
 numLink (Title $title, $offset, $limit, array $query, $link, $tooltipMsg, $class)
 Helper function for viewPrevNext() that generates links.
 truncate_endBracket (&$tag, $tagType, $lastCh, &$openTags)
 truncateHtml() helper function (a) push or pop $tag from $openTags as needed (b) clear $tag value
 truncate_skip (&$ret, $text, $search, $start, $len=null)
 truncateHtml() helper function like strcspn() but adds the skipped chars to $ret

Static Private Member Functions

static hebrewYearStart ($year)
 This calculates the Hebrew year start, as days since 1 September.
static tsToHebrew ($ts)
 Converting Gregorian dates to Hebrew dates.
static tsToHijri ($ts)
 Converting Gregorian dates to Hijri dates.
static tsToIranian ($ts)
 Algorithm by Roozbeh Pournader and Mohammad Toossi to convert Gregorian dates to Iranian dates.
static tsToYear ($ts, $cName)
 Algorithm to convert Gregorian dates to Thai solar dates, Minguo dates or Minguo dates.

Private Attributes

 $mHtmlCode = null

Static Private Attributes

static $GREG_DAYS = array( 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 )
static $IRANIAN_DAYS = array( 31, 31, 31, 31, 31, 31, 30, 30, 30, 30, 30, 29 )

Detailed Description

Internationalisation code.

Definition at line 60 of file Language.php.


Constructor & Destructor Documentation

Language::__construct (  ) 
Language::__destruct (  ) 

Reduce memory usage.

Definition at line 314 of file Language.php.

References $value.


Member Function Documentation

Language::addMagicWordsByLang ( newWords  ) 

Add magic words to the extension array.

Parameters:
$newWords array

Definition at line 2777 of file Language.php.

Language::alignEnd (  ) 

Return 'right' or 'left' as appropriate alignment for line-end for this language's text direction.

Should be equivalent to CSS3 'end' text-align value....

Returns:
String

Definition at line 2667 of file Language.php.

Language::alignStart (  ) 

Return 'left' or 'right' as appropriate alignment for line-start for this language's text direction.

Should be equivalent to CSS3 'start' text-align value....

Returns:
String

Definition at line 2655 of file Language.php.

Language::armourMath ( text  ) 

Put custom tags (e.g.

-{ }-) around math to prevent conversion

Parameters:
$text string
Returns:
string

Definition at line 3514 of file Language.php.

Language::autoConvertToAllVariants ( text  ) 

convert text to all supported variants

Parameters:
$text string
Returns:
array

Definition at line 3464 of file Language.php.

Language::capitalizeAllNouns (  ) 
Returns:
array

Definition at line 2706 of file Language.php.

Language::caseFold ( s  ) 

Return a case-folded representation of $s.

This is a representation such that caseFold($s1)==caseFold($s2) if $s1 and $s2 are the same except for the case of their characters. It is not necessary for the value returned to make sense when displayed.

Do *not* perform any other normalisation in this function. If a caller uses this function when it should be using a more general normalisation function, then fix the caller.

Parameters:
$s string
Returns:
string

Definition at line 2371 of file Language.php.

References $s.

Language::checkTitleEncoding ( s  ) 
Parameters:
$s string
Returns:
string

Reimplemented in LanguageEo.

Definition at line 2379 of file Language.php.

References $s, and wfDebugDieBacktrace().

static Language::classFromCode ( code  )  [static]
Parameters:
$code 
Returns:
String Name of the language class

Definition at line 255 of file Language.php.

References ucfirst().

Referenced by newFromCode().

Language::commafy ( _  ) 

Adds commas to a given number.

Since:
1.19
Parameters:
$_ mixed
Returns:
string

Reimplemented in LanguageBe_tarask, LanguageBg, LanguageEt, LanguageHy, LanguageKaa, LanguageKk_cyrl, LanguageKm, LanguageKsh, LanguageKu_ku, LanguageMy, LanguagePl, LanguageRu, and LanguageUk.

Definition at line 2883 of file Language.php.

References $digitGroupingPattern, and $matches.

Language::commaList ( array $  list  ) 

Take a list of strings and build a locale-friendly comma-separated list, using the local comma-separator message.

Parameters:
$list array of strings to put in a comma list
Returns:
string

Definition at line 2985 of file Language.php.

References wfMsgExt().

Language::convert ( text  ) 

convert text to different variants of a language.

Parameters:
$text string
Returns:
string

Definition at line 3474 of file Language.php.

Language::convertCategoryKey ( key  ) 
Parameters:
$key string
Returns:
string

Definition at line 3533 of file Language.php.

static Language::convertDoubleWidth ( string  )  [static, protected]

convert double-width roman characters to single-width.

range: ff00-ff5f ~= 0020-007f

Parameters:
$string string
Returns:
string

Definition at line 2447 of file Language.php.

Referenced by LanguageZh::convertForSearchResult(), LanguageGan::convertForSearchResult(), and LanguageYue::normalizeForSearch().

Language::convertForSearchResult ( termsArray  ) 
Parameters:
$termsArray array
Returns:
array

Reimplemented in LanguageGan, and LanguageZh.

Definition at line 2477 of file Language.php.

Language::convertGrammar ( word,
case 
)

Grammatical transformations, needed for inflected languages Invoked by putting {{grammar:case|word}} in a message.

Parameters:
$word string
$case string
Returns:
string

Reimplemented in LanguageBs, LanguageCu, LanguageDsb, LanguageFi, LanguageGa, LanguageHe, LanguageHsb, LanguageHu, LanguageHy, LanguageKaa, LanguageKk, LanguageKsh, LanguageLa, LanguageOs, LanguageRu, LanguageSl, LanguageTyv, and LanguageUk.

Definition at line 3302 of file Language.php.

References $wgGrammarForms.

Language::convertHtml ( text,
isTitle = false 
)

Perform output conversion on a string, and encode for safe HTML output.

Parameters:
$text String text to be converted
$isTitle Bool whether this conversion is for the article title
Returns:
string
Todo:
this should get integrated somewhere sane

Definition at line 3525 of file Language.php.

Language::convertLinkToAllVariants ( text  ) 

If a language supports multiple variants, converts text into an array of all possible variants of the text: 'variant' => text in that variant.

Deprecated:
since 1.17 Use autoConvertToAllVariants()
Parameters:
$text string
Returns:
string

Definition at line 3595 of file Language.php.

Language::convertPlural ( count,
forms 
)

Plural form transformations, needed for some languages.

For example, there are 3 form of plural in Russian and Polish, depending on "count mod 10". See [[w:Plural]] For English it is pretty simple.

Invoked by putting {{plural:count|wordform1|wordform2}} or {{plural:count|wordform1|wordform2|wordform3}}

Example: {{plural:{{NUMBEROFARTICLES}}|article|articles}}

Parameters:
$count Integer: non-localized number
$forms Array: different plural forms
Returns:
string Correct form of plural for $count in this language

Reimplemented in LanguageAm, LanguageAr, LanguageBe, LanguageBe_tarask, LanguageBh, LanguageBs, LanguageCs, LanguageCu, LanguageCy, LanguageDsb, LanguageFr, LanguageGa, LanguageGd, LanguageGv, LanguageHe, LanguageHi, LanguageHr, LanguageHsb, LanguageHy, LanguageKsh, LanguageLn, LanguageLt, LanguageLv, LanguageMg, LanguageMk, LanguageMo, LanguageMt, LanguageNso, LanguagePl, LanguageRo, LanguageRu, LanguageSe, LanguageSgs, LanguageSh, LanguageSk, LanguageSl, LanguageSma, LanguageSr, LanguageSr_ec, LanguageSr_el, LanguageTi, LanguageTl, LanguageUk, and LanguageWa.

Definition at line 3369 of file Language.php.

References $count.

Language::convertTitle ( title  ) 

Convert a Title object to a string in the preferred variant.

Parameters:
$title Title
Returns:
string

Definition at line 3484 of file Language.php.

References $title.

Language::date ( ts,
adj = false,
format = true,
timecorrection = false 
)
Parameters:
$ts Mixed: the time format which needs to be turned into a date('YmdHis') format with wfTimestamp(TS_MW,$ts)
$adj Bool: whether to adjust the time output according to the user configured offset ($timecorrection)
$format Mixed: true to use user's date format preference
$timecorrection String|bool the time offset as returned by validateTimeZone() in Special:Preferences
Returns:
string

Reimplemented in LanguageWa.

Definition at line 1879 of file Language.php.

References wfTimestamp().

Referenced by LanguageFi::translateBlockExpiry().

Language::dateFormat ( usePrefs = true  ) 

This is meant to be used by time(), date(), and timeanddate() to get the date preference they're supposed to use, it should be used in all children.

function timeanddate([...], $format = true) { $datePreference = $this->dateFormat($format); [...] }

Parameters:
$usePrefs Mixed: if true, the user's preference is used if false, the site/language default is used if int/string, assumed to be a format.
Returns:
string

Definition at line 1824 of file Language.php.

References $wgUser, and User::getDefaultOption().

Referenced by LanguageWa::date(), and LanguageWa::timeanddate().

Language::digitGroupingPattern (  ) 
Returns:
String

Definition at line 2934 of file Language.php.

Language::digitTransformTable (  ) 
Returns:
array

Definition at line 2941 of file Language.php.

Language::doMagicHook (  )  [protected]

Definition at line 2735 of file Language.php.

References wfProfileIn(), wfProfileOut(), and wfRunHooks().

Language::emphasize ( text  ) 

Italic is unsuitable for some languages.

Parameters:
$text String: the text to be emphasized.
Returns:
string

Reimplemented in LanguageJa.

Definition at line 2810 of file Language.php.

static Language::factory ( code  )  [static]

Get a cached language object for a given language code.

Parameters:
$code String
Returns:
Language

Definition at line 163 of file Language.php.

References newFromCode().

Referenced by CliInstaller::__construct(), StubContLang::_newObject(), UpdateMediaWiki::execute(), PurgeParserCache::execute(), LangMemUsage::execute(), DateFormats::execute(), ApiQueryAllMessages::execute(), ApiParse::execute(), ParserTest::fuzzTest(), ResourceLoaderContext::getDirection(), RequestContext::getLanguage(), Message::inLanguage(), LoginForm::processLogin(), ParserTest::runTestsFromFiles(), RequestContext::setLanguage(), DerivativeContext::setLanguage(), SideBarTest::setUp(), MediaWikiLangTestCase::setUp(), LanguageWaTest::setUp(), LanguageUkTest::setUp(), LanguageTrTest::setUp(), LanguageTlTest::setUp(), LanguageTiTest::setUp(), LanguageTest::setUp(), LanguageSrTest::setUp(), LanguageSmaTest::setUp(), LanguageSlTest::setUp(), LanguageSkTest::setUp(), LanguageShTest::setUp(), LanguageSgsTest::setUp(), LanguageSeTest::setUp(), LanguageRuTest::setUp(), LanguageRoTest::setUp(), LanguagePlTest::setUp(), LanguageNsoTest::setUp(), LanguageNlTest::setUp(), LanguageMtTest::setUp(), LanguageMoTest::setUp(), LanguageMlTest::setUp(), LanguageMkTest::setUp(), LanguageMgTest::setUp(), LanguageLvTest::setUp(), LanguageLtTest::setUp(), LanguageLnTest::setUp(), LanguageKshTest::setUp(), LanguageHyTest::setUp(), LanguageHsbTest::setUp(), LanguageHrTest::setUp(), LanguageHiTest::setUp(), LanguageHeTest::setUp(), LanguageGvTest::setUp(), LanguageGdTest::setUp(), LanguageGaTest::setUp(), LanguageFrTest::setUp(), LanguageDsbTest::setUp(), LanguageCyTest::setUp(), LanguageCuTest::setUp(), LanguageCsTest::setUp(), LanguageBsTest::setUp(), LanguageBhTest::setUp(), LanguageBeTest::setUp(), LanguageBeTaraskTest::setUp(), LanguageArTest::setUp(), LanguageAmTest::setUp(), XmlTest::setUp(), TitlePermissionTest::setUp(), TestSample::setUp(), RevisionTest::setUp(), ParserOptionsTest::setUp(), NewParserTest::setUp(), MagicVariableTest::setUp(), LanguageConverterTest::setUp(), HtmlTest::setUp(), BlockTest::setUp(), ApiTestCase::setUp(), NewParserTest::setupGlobals(), ParserTest::setupGlobals(), WebInstaller::setupLanguage(), ParserOptions::setUserLang(), ArticleTablesTest::testbug14404(), LanguageConverterTest::testGetPreferredVariantDefaultLanguageVsUrlVariant(), LanguageConverterTest::testGetPreferredVariantHeaderUserVsUrl(), MessageTest::testInContentLanguage(), MessageTest::testInLanguage(), TimeAdjustTest::testUserAdjust(), wfGetLangObj(), and wfInstallerMain().

Language::fallback8bitEncoding (  ) 
Returns:
array

Definition at line 2401 of file Language.php.

static Language::fetchLanguageName ( code,
inLanguage = null,
include = 'all' 
) [static]
Parameters:
$code string: The code of the language for which to get the name
$inLanguage null|string: Code of language in which to return the name (null for autonyms)
$include string: 'all', 'mw' or 'mwfile'; see fetchLanguageNames()
Returns:
string: Language name or empty
Since:
1.20

Definition at line 766 of file Language.php.

Referenced by MessageCache::figureMessage(), FormatMetadata::getFormattedData(), getVariantname(), wikiStatsOutput::heading(), FormatMetadata::langItem(), CoreParserFunctions::language(), ApiParse::languagesHtml(), LegacyTemplate::otherLanguages(), SkinTemplate::outputPage(), and CheckLanguageCLI::outputWiki().

static Language::fetchLanguageNames ( inLanguage = null,
include = 'mw' 
) [static]

Get an array of language names, indexed by code.

Parameters:
$inLanguage null|string: Code of language in which to return the names Use null for autonyms (native names)
$include string: 'all' all available languages 'mw' only if the language is defined in MediaWiki or wgExtraLanguageNames 'mwfile' only if the language is in 'mw' *and* has a message file
Returns:
array|bool: language code => language name, false if $include is wrong
Since:
1.20

Definition at line 708 of file Language.php.

Referenced by languages::__construct(), LanguageConverter::__construct(), ApiQuerySiteinfo::appendInterwikiMap(), ApiQuerySiteinfo::appendLanguages(), AllmessagesTablePager::buildForm(), MessageCache::clear(), RebuildLocalisationCache::execute(), WebInstaller_Language::execute(), WebInstaller::getAcceptLanguage(), WebInstaller_Language::getLanguageSelector(), Xml::languageSelector(), Preferences::profilePreferences(), MessageCache::replace(), and wfGetLangObj().

Language::findVariantLink ( &$  link,
&$  nt,
ignoreOtherCond = false 
)

If a language supports multiple variants, it is possible that non-existing link in one variant actually exists in another variant.

this function tries to find it. See e.g. LanguageZh.php

Parameters:
$link String: the name of the link
$nt Mixed: the title object of the link
$ignoreOtherCond Boolean: to disable other conditions when we need to transclude a template or update a category's link
Returns:
null the input parameters may be modified upon return

Definition at line 3580 of file Language.php.

Language::firstChar ( s  ) 

Get the first character of a string.

Parameters:
$s string
Returns:
string

Definition at line 2489 of file Language.php.

References $matches, $s, and utf8ToCodepoint().

Language::fixVariableInNamespace ( talk  ) 
Parameters:
$talk 
Returns:
mixed

Definition at line 3814 of file Language.php.

References $wgMetaNamespace.

Referenced by getNamespaceAliases(), and getNamespaces().

Language::formatBitrate ( bps  ) 

Format a bitrate for output, using an appropriate unit (bps, kbps, Mbps, Gbps, Tbps, Pbps, Ebps, Zbps or Ybps) according to the magnitude in question.

This use base 1000. For base 1024 use formatSize(), for another base see formatComputingNumbers()

Parameters:
$bps int
Returns:
string

Definition at line 3998 of file Language.php.

Language::formatComputingNumbers ( size,
boundary,
messageKey 
)
Parameters:
$size int Size of the unit
$boundary int Size boundary (1000, or 1024 in most cases)
$messageKey string Message key to be uesd
Returns:
string

Definition at line 4008 of file Language.php.

References $size.

Language::formatDuration ( seconds,
array $  chosenIntervals = array() 
)

Takes a number of seconds and turns it into a text using values such as hours and minutes.

Since:
1.20
Parameters:
integer $seconds The amount of seconds.
array $chosenIntervals The intervals to enable.
Returns:
string

Definition at line 1937 of file Language.php.

Language::formatExpiry ( expiry,
format = true 
)

Decode an expiry (block, protection, etc) which has come from the DB.

: why are we returnings DBMS-dependent strings???

Parameters:
$expiry String: Database expiry String
$format Bool|Int true to process using language functions, or TS_ constant to return the expiry in a given timestamp
Returns:
String

Definition at line 3871 of file Language.php.

References wfGetDB(), wfMessage(), and wfTimestamp().

Language::formatNum ( number,
nocommafy = false 
)

Normally we output all numbers in plain en_US style, that is 293,291.235 for twohundredninetythreethousand-twohundredninetyone point twohundredthirtyfive.

However this is not suitable for all languages, some such as Pakaran want ੨੯੩,੨੯੫.੨੩੫ and others such as Icelandic just want to use commas instead of dots, and dots instead of commas like "293.291,235".

An example of this function being called: wfMsg( 'message', $wgLang->formatNum( $num ) )

See LanguageGu.php for the Gujarati implementation and $separatorTransformTable on MessageIs.php for the , => . and . => , implementation.

Todo:
check if it's viable to use localeconv() for the decimal separator thing.
Parameters:
$number Mixed: the string to be formatted, should be an integer or a floating point number.
$nocommafy Bool: set to true for special numbers like dates
Returns:
string

Definition at line 2838 of file Language.php.

References $s, and $wgTranslateNumerals.

Language::formatSize ( size  ) 

Format a size in bytes for output, using an appropriate unit (B, KB, MB, GB, TB, PB, EB, ZB or YB) according to the magnitude in question.

This method use base 1024. For base 1000 use formatBitrate(), for another base see formatComputingNumbers()

Parameters:
$size int Size to format
Returns:
string Plain text (not HTML)

Definition at line 4046 of file Language.php.

References $size.

Language::formatTimePeriod ( seconds,
format = array() 
)
Todo:
Document
Parameters:
$seconds int|float
$format Array Optional If $format['avoid'] == 'avoidseconds' - don't mention seconds if $seconds >= 1 hour If $format['avoid'] == 'avoidminutes' - don't mention seconds/minutes if $seconds > 48 hours If $format['noabbrevs'] is true - use 'seconds' and friends instead of 'seconds-abbrev' and friends For backwards compatibility, $format may also be one of the strings 'avoidseconds' or 'avoidminutes'
Returns:
string

Definition at line 3899 of file Language.php.

References $s, and wfMessage().

Language::gender ( gender,
forms 
)

Provides an alternative text depending on specified gender.

Usage {{gender:username|masculine|feminine|neutral}}. username is optional, in which case the gender of current user is used, but only in (some) interface messages; otherwise default gender is used.

If no forms are given, an empty string is returned. If only one form is given, it will be returned unconditionally. These details are implied by the caller and cannot be overridden in subclasses.

If more than one form is given, the default is to use the neutral one if it is specified, and to use the masculine one otherwise. These details can be overridden in subclasses.

Parameters:
$gender string
$forms array
Returns:
string

Definition at line 3340 of file Language.php.

Language::getAllMessages (  ) 
Returns:
array

Definition at line 2103 of file Language.php.

Language::getArrow (  ) 

An arrow, depending on the language direction.

Returns:
string

Definition at line 2715 of file Language.php.

Language::getBookstoreList (  ) 

Exports $wgBookstoreListEn.

Returns:
array

Definition at line 348 of file Language.php.

static Language::getCaseMaps (  )  [static]
Exceptions:
MWException 
Returns:
array

Definition at line 3843 of file Language.php.

References $wikiLowerChars, $wikiUpperChars, wfGetPrecompiledData(), wfProfileIn(), and wfProfileOut().

static Language::getClassFileName ( code  )  [static]
Parameters:
$code string
Returns:
string

Definition at line 3731 of file Language.php.

References $IP.

Language::getCode (  ) 

Get the RFC 3066 code for this language object.

Returns:
string

Definition at line 3654 of file Language.php.

Referenced by LanguageHu::convertGrammar().

static Language::getCodeFromFileName ( filename,
prefix = 'Language',
suffix = '.php' 
) [static]

Get the language code from a file name.

Inverse of getFileName()

Parameters:
$filename string $prefix . $languageCode . $suffix
$prefix string Prefix before the language code
$suffix string Suffix after the language code
Returns:
string Language code, or false if $prefix or $suffix isn't found

Definition at line 3706 of file Language.php.

Language::getConverter (  ) 

Return the LanguageConverter used in the Language.

Since:
1.19
Returns:
LanguageConverter

Definition at line 3454 of file Language.php.

Language::getConvRuleTitle (  ) 

Get the conversion rule title, if any.

Returns:
string

Definition at line 4133 of file Language.php.

Language::getDateFormats (  ) 
Returns:
array

Definition at line 623 of file Language.php.

Language::getDateFormatString ( type,
pref 
)

Get a format string for a given type and preference.

Parameters:
$type string May be date, time or both
$pref string The format name as it appears in Messages*.php
Returns:
string

Definition at line 1852 of file Language.php.

Language::getDatePreferenceMigrationMap (  ) 
Returns:
array

Definition at line 643 of file Language.php.

Language::getDatePreferences (  ) 
Returns:
array

Definition at line 616 of file Language.php.

Language::getDefaultDateFormat (  ) 
Returns:
array|string

Definition at line 630 of file Language.php.

Language::getDefaultVariant (  ) 
Returns:
string

Definition at line 3557 of file Language.php.

Language::getDir (  ) 

Return the correct HTML 'dir' attribute value for this language.

Returns:
String

Definition at line 2643 of file Language.php.

Language::getDirMark ( opposite = false  ) 

A hidden direction mark (LRM or RLM), depending on the language direction.

This function produces them as invisible Unicode characters and the output may be hard to read and debug, so it should only be used when the output is plain text or can be escaped. When the output is HTML, use getDirMarkEntity() instead.

Parameters:
$opposite Boolean Get the direction mark opposite to your language
Returns:
string

Definition at line 2696 of file Language.php.

Language::getDirMarkEntity ( opposite = false  ) 

A hidden direction mark (LRM or RLM), depending on the language direction.

Unlike getDirMark(), this function returns the character as an HTML entity. This function should be used when the output is guaranteed to be HTML, because it makes the output HTML source code more readable. When the output is plain text or can be escaped, getDirMark() should be used.

Parameters:
$opposite Boolean Get the direction mark opposite to your language
Returns:
string

Definition at line 2681 of file Language.php.

Language::getDurationIntervals ( seconds,
array $  chosenIntervals = array() 
)

Takes a number of seconds and returns an array with a set of corresponding intervals.

For example 65 will be turned into array( minutes => 1, seconds => 5 ).

Since:
1.20
Parameters:
integer $seconds The amount of seconds.
array $chosenIntervals The intervals to enable.
Returns:
array

Definition at line 1961 of file Language.php.

References $value.

Language::getExtraHashOptions (  ) 

returns language specific options used by User::getPageRenderHash() for example, the preferred language variant

Returns:
string

Definition at line 3605 of file Language.php.

Language::getExtraUserToggles (  ) 
Returns:
array

Definition at line 658 of file Language.php.

static Language::getFallbackFor ( code  )  [static]

Get the first fallback for a given language.

Parameters:
$code string
Returns:
bool|string

Definition at line 3743 of file Language.php.

References isValidBuiltInCode().

Referenced by getFallbackLanguageCode().

Language::getFallbackLanguageCode (  ) 

Same as getFallbacksFor for current language.

Returns:
array|bool
Deprecated:
in 1.19

Definition at line 331 of file Language.php.

References getFallbackFor(), and wfDeprecated().

Language::getFallbackLanguages (  ) 
Returns:
array
Since:
1.19

Definition at line 340 of file Language.php.

References getFallbacksFor().

static Language::getFallbacksFor ( code  )  [static]

Get the ordered list of fallback languages.

Since:
1.19
Parameters:
$code string Language code
Returns:
array

Definition at line 3760 of file Language.php.

References isValidBuiltInCode().

Referenced by getFallbackLanguages(), and newFromCode().

static Language::getFileName ( prefix = 'Language',
code,
suffix = '.php' 
) [static]

Get the name of a file for a certain language code.

Parameters:
$prefix string Prepend this to the filename
$code string Language code
$suffix string Append this to the filename
Exceptions:
MWException 
Returns:
string $prefix . $mangledCode . $suffix

Definition at line 3688 of file Language.php.

References isValidCode().

Referenced by MessageWriter::writeMessagesToFile().

Language::getFormattedNamespaces (  ) 

A convenience function that returns the same thing as getNamespaces() except with the array values changed to ' ' where it found '_', useful for producing output to be displayed e.g.

in <select> forms.

Returns:
array

Definition at line 405 of file Language.php.

References getNamespaces().

Language::getFormattedNsText ( index  ) 

A convenience function that returns the same thing as getNsText() except with '_' changed to ' ', useful for producing output.

Parameters:
$index string
Returns:
array

Definition at line 437 of file Language.php.

References getNsText().

Language::getGenderNsText ( index,
gender 
)

Returns gender-dependent namespace alias if available.

Parameters:
$index Int: namespace index
$gender String: gender key (male, female... )
Returns:
String
Since:
1.18

Definition at line 449 of file Language.php.

References $wgExtraGenderNamespaces, and getNsText().

Language::getGrammarForms (  ) 

Get the grammar forms for the content language.

Returns:
array of grammar forms
Since:
1.20

Definition at line 3314 of file Language.php.

References $wgGrammarForms.

Language::getHebrewCalendarMonthName ( key  ) 
Parameters:
$key string
Returns:
string

Definition at line 866 of file Language.php.

Language::getHebrewCalendarMonthNameGen ( key  ) 
Parameters:
$key string
Returns:
string

Definition at line 874 of file Language.php.

Language::getHijriCalendarMonthName ( key  ) 
Parameters:
$key string
Returns:
string

Definition at line 882 of file Language.php.

Language::getHtmlCode (  ) 

Get the code in Bcp47 format which we can use inside of html lang="" tags.

Since:
1.19
Returns:
string

Definition at line 3664 of file Language.php.

References wfBCP47().

Language::getImageFile ( image  ) 
Parameters:
$image 
Returns:
array|null

Definition at line 651 of file Language.php.

Language::getIranianCalendarMonthName ( key  ) 
Parameters:
$key string
Returns:
string

Definition at line 858 of file Language.php.

Language::getLangObj (  ) 
Returns:
Language

Definition at line 3645 of file Language.php.

Language::getLanguageName ( code  ) 

Get the native language name of $code.

Only if defined in MediaWiki, no other data like CLDR.

Parameters:
$code string
Returns:
string
Deprecated:
in 1.20, use fetchLanguageName()

Definition at line 788 of file Language.php.

static Language::getLanguageNames ( customisedOnly = false  )  [static]

Get native language names, indexed by code.

Only those defined in MediaWiki, no other data like CLDR. If $customisedOnly is true, only returns codes with a messages file

Parameters:
$customisedOnly bool
Returns:
array
Deprecated:
in 1.20, use fetchLanguageNames()

Definition at line 680 of file Language.php.

static Language::getLocalisationCache (  )  [static]
Language::getLocalNsIndex ( text  ) 

Get a namespace key by value, case insensitive.

Only matches namespace names for the current language, not the canonical ones defined in Namespace.php.

Parameters:
$text String
Returns:
mixed An integer if $text is a valid value otherwise false

Definition at line 486 of file Language.php.

References getNamespaceIds(), and lc().

Language::getMagic ( mw  ) 

Fill a MagicWord object with data from here.

Parameters:
$mw 

Definition at line 2750 of file Language.php.

References $magicWords.

Language::getMagicWords (  ) 
Returns:
array

Definition at line 2731 of file Language.php.

Language::getMessage ( key  ) 
Parameters:
$key string
Returns:
array|null

Reimplemented in LanguageQqx.

Definition at line 2096 of file Language.php.

static Language::getMessageFor ( key,
code 
) [static]

Get a message for a given language.

Parameters:
$key string
$code string
Returns:
string

Definition at line 3794 of file Language.php.

Referenced by MessageCache::get().

Language::getMessageFromDB ( msg  ) 

Get a message from the MediaWiki namespace.

Parameters:
$msg String: message name
Returns:
string

Definition at line 777 of file Language.php.

Referenced by getVariantname().

static Language::getMessageKeysFor ( code  )  [static]

Get all message keys for a given language.

This is a faster alternative to array_keys( Language::getMessagesFor( $code ) )

Since:
1.19
Parameters:
$code string Language code
Returns:
array of message keys (strings)

Definition at line 3806 of file Language.php.

Referenced by ApiQueryAllMessages::execute().

static Language::getMessagesFileName ( code  )  [static]
Parameters:
$code string
Returns:
string

Definition at line 3720 of file Language.php.

References $file, $IP, and wfRunHooks().

Referenced by Digit2Html::execute(), LocalisationCache::initLanguage(), languages::loadFile(), LocalisationCache::recache(), and MessageWriter::writeMessagesToFile().

static Language::getMessagesFor ( code  )  [static]

Get all messages for a given language WARNING: this may take a long time.

If you just need all message *keys* but need the *contents* of only a few messages, consider using getMessageKeysFor().

Parameters:
$code string
Returns:
array

Definition at line 3782 of file Language.php.

Referenced by DumpMessages::execute(), and AllTrans::execute().

Language::getMonthAbbreviation ( key  ) 
Parameters:
$key string
Returns:
string

Definition at line 823 of file Language.php.

Language::getMonthAbbreviationsArray (  ) 
Returns:
array

Definition at line 830 of file Language.php.

Language::getMonthName ( key  ) 
Parameters:
$key string
Returns:
string

Definition at line 796 of file Language.php.

Referenced by LanguageWa::date().

Language::getMonthNameGen ( key  ) 
Parameters:
$key string
Returns:
string

Definition at line 815 of file Language.php.

Language::getMonthNamesArray (  ) 
Returns:
array

Definition at line 803 of file Language.php.

Language::getNamespaceAliases (  ) 
Returns:
array

Definition at line 495 of file Language.php.

References $wgExtraGenderNamespaces, and fixVariableInNamespace().

Referenced by getNamespaceIds().

Language::getNamespaceIds (  ) 
Returns:
array

Definition at line 526 of file Language.php.

References $wgNamespaceAliases, getNamespaceAliases(), getNamespaces(), and lc().

Referenced by getLocalNsIndex(), and getNsIndex().

Language::getNamespaces (  ) 
Language::getNsIndex ( text  ) 

Get a namespace key by value, case insensitive.

Canonical namespace names override custom ones defined for the current language.

Parameters:
$text String
Returns:
mixed An integer if $text is a valid value otherwise false

Definition at line 556 of file Language.php.

References MWNamespace::getCanonicalIndex(), getNamespaceIds(), and lc().

Language::getNsText ( index  ) 

Get a namespace value by key $mw_ns = $wgContLang->getNsText( NS_MEDIAWIKI ); echo $mw_ns; // prints 'MediaWiki'

Parameters:
$index Int: the array key of the namespace to return
Returns:
mixed, string if the namespace value exists, otherwise false

Definition at line 423 of file Language.php.

References getNamespaces().

Referenced by getFormattedNsText(), and getGenderNsText().

Language::getParsedTitle (  ) 

For languages that support multiple variants, the title of an article may be displayed differently in different variants.

this function returns the apporiate title defined in the body of the article.

Returns:
string

Definition at line 3616 of file Language.php.

Language::getPreferredVariant (  ) 
Returns:
string

Definition at line 3550 of file Language.php.

Referenced by LanguageKk::convertGrammar(), LanguageKk::isRTL(), LanguageKk::lcfirst(), and LanguageKk::ucfirst().

Language::getQuickbarSettings (  ) 
Returns:
array

Definition at line 602 of file Language.php.

Language::getSpecialPageAliases (  ) 

Get special page names, as an associative array case folded alias => real name.

Definition at line 2791 of file Language.php.

References wfRunHooks().

static Language::getTranslatedLanguageNames ( code  )  [static]

Get translated language names.

This is done on best effort and by default this is exactly the same as Language::getLanguageNames. The CLDR extension provides translated names.

Parameters:
$code String Language code.
Returns:
Array language code => language name
Since:
1.18.0
Deprecated:
in 1.20, use fetchLanguageNames()

Definition at line 693 of file Language.php.

Language::getURLVariant (  ) 
Returns:
string

Definition at line 3564 of file Language.php.

Language::getUserToggle ( tog  ) 
Parameters:
$tog 
Returns:
string

Definition at line 666 of file Language.php.

Language::getVariantname ( code,
usemsg = true 
)

short names for language variants used for language conversion links.

Parameters:
$code String
$usemsg bool Use the "variantname-xyz" message if it exists
Returns:
string

Definition at line 573 of file Language.php.

References fetchLanguageName(), getMessageFromDB(), and wfMessage().

Language::getVariants (  ) 

Get the list of variants supported by this language see sample implementation in LanguageZh.php.

Returns:
array an array of language codes

Definition at line 3543 of file Language.php.

Language::getWeekdayAbbreviation ( key  ) 
Parameters:
$key string
Returns:
string

Definition at line 850 of file Language.php.

Language::getWeekdayName ( key  ) 
Parameters:
$key string
Returns:
string

Definition at line 842 of file Language.php.

Language::hasVariant ( variant  ) 

Check if the language has the specific variant.

Since:
1.19
Parameters:
$variant string
Returns:
bool

Definition at line 3504 of file Language.php.

Language::hasVariants (  ) 

Check if this is a language with variants.

Returns:
bool

Definition at line 3493 of file Language.php.

Language::hasWordBreaks (  ) 

Most writing systems use whitespace to break up words.

Some languages such as Chinese don't conventionally do this, which requires special handling when breaking up words for searching etc.

Returns:
bool

Reimplemented in LanguageYue, and LanguageZh_hans.

Definition at line 2413 of file Language.php.

static Language::hebrewNumeral ( num  )  [static]

Hebrew Gematria number formatting up to 9999.

Parameters:
$num int
Returns:
string

Definition at line 1675 of file Language.php.

References $s.

static Language::hebrewYearStart ( year  )  [static, private]

This calculates the Hebrew year start, as days since 1 September.

Based on Carl Friedrich Gauss algorithm for finding Easter date. Used for Hebrew date.

Parameters:
$year int
Returns:
string

Definition at line 1528 of file Language.php.

Language::iconv ( in,
out,
string 
)
Parameters:
$in 
$out 
$string 
Returns:
string

Reimplemented in LanguageEo.

Definition at line 2113 of file Language.php.

References $in, $out, wfRestoreWarnings(), and wfSuppressWarnings().

Language::initContLang (  ) 

Hook which will be called if this is the content language.

Descendants can use this to register hook functions or modify globals

Definition at line 324 of file Language.php.

Language::initEncoding (  ) 

Reimplemented in LanguageEo.

Definition at line 2541 of file Language.php.

static Language::insertSpace ( string,
pattern 
) [static, protected]
Parameters:
$string string
$pattern string
Returns:
string

Definition at line 2467 of file Language.php.

Referenced by LanguageZh_hans::segmentByWord(), LanguageYue::segmentByWord(), and LanguageJa::segmentByWord().

Language::internalUserTimeAndDate ( type,
ts,
User user,
array $  options 
) [private]

Internal helper function for userDate(), userTime() and userTimeAndDate().

Parameters:
$type String: can be 'date', 'time' or 'both'
$ts Mixed: the time format which needs to be turned into a date('YmdHis') format with wfTimestamp(TS_MW,$ts)
$user User object used to get preferences for timezone and format
$options Array, can contain the following keys:

  • 'timecorrection': time correction, can have the following values:
    • true: use user's preference
    • false: don't use time correction
    • integer: value of time correction in minutes
  • 'format': format to use, can have the following values:
    • true: use user's preference
    • false: use default preference
    • string: format to use
Since:
1.19
Returns:
String

Definition at line 2003 of file Language.php.

References User::getDatePreference(), User::getOption(), and wfTimestamp().

Language::isMultibyte ( str  ) 
Parameters:
$str string
Returns:
bool

Definition at line 2284 of file Language.php.

Language::isRTL (  ) 

For right-to-left language support.

Returns:
bool

Reimplemented in LanguageKk.

Definition at line 2635 of file Language.php.

static Language::isValidBuiltInCode ( code  )  [static]

Returns true if a language code is of a valid form for the purposes of internal customisation of MediaWiki, via Messages*.php.

Parameters:
$code string
Since:
1.18
Returns:
bool

Definition at line 247 of file Language.php.

Referenced by getFallbackFor(), getFallbacksFor(), LocalisationCache::initLanguage(), newFromCode(), LanguageTest::testBuiltInCodeValidation(), and LanguageTest::testBuiltInCodeValidationRejectUnderscore().

static Language::isValidCode ( code  )  [static]

Returns true if a language code string is of a valid form, whether or not it exists.

This includes codes which are used solely for customisation via the MediaWiki namespace.

Parameters:
$code string
Returns:
bool

Definition at line 232 of file Language.php.

References Title::getTitleInvalidRegex().

Referenced by getFileName(), newFromCode(), and RequestContext::sanitizeLangCode().

Language::lc ( str,
first = false 
)
Parameters:
$str string
$first bool
Returns:
mixed|string

Definition at line 2255 of file Language.php.

Referenced by getLocalNsIndex(), getNamespaceIds(), and getNsIndex().

Language::lcCallback ( matches  ) 
Parameters:
$matches array
Returns:
string

Definition at line 2158 of file Language.php.

References $matches, and $wikiLowerChars.

Language::lcfirst ( str  ) 
Parameters:
$str string
Returns:
mixed|string

Reimplemented in LanguageKaa, LanguageKk, and LanguageTr.

Definition at line 2236 of file Language.php.

Language::linkPrefixExtension (  ) 

To allow "foo[[bar]]" to extend the link over the whole word "foobar".

Returns:
bool

Definition at line 2724 of file Language.php.

Language::linkTrail (  ) 

A regular expression to match legal word-trailing characters which should be merged onto a link of the form [[foo]]bar.

Returns:
string

Definition at line 3638 of file Language.php.

Language::listToText ( array $  l  ) 

Take a list of strings and build a locale-friendly comma-separated list, using the local comma-separator message.

The last two strings are chained with an "and".

Parameters:
$l Array
Returns:
string

Definition at line 2960 of file Language.php.

References $s.

Language::markNoConversion ( text,
noParse = false 
)

Enclose a string with the "no conversion" tag.

This is used by various functions in the Parser

Parameters:
$text String: text to be tagged for no conversion
$noParse bool
Returns:
string the tagged text

Definition at line 3628 of file Language.php.

Language::needsGenderDistinction (  ) 

Whether this language makes distinguishes genders for example in namespaces.

Returns:
bool
Since:
1.18

Definition at line 462 of file Language.php.

References $wgExtraGenderNamespaces, and $wgExtraNamespaces.

static Language::newFromCode ( code  )  [static, protected]

Create a language object for a given language code.

Parameters:
$code String
Exceptions:
MWException 
Returns:
Language

Definition at line 180 of file Language.php.

References MWInit::classExists(), classFromCode(), getFallbacksFor(), isValidBuiltInCode(), isValidCode(), and preloadLanguageClass().

Referenced by factory().

Language::normalize ( s  ) 

Convert a UTF-8 string to normal form C.

In Malayalam and Arabic, this also cleans up certain backwards-compatible sequences, converting them to the modern Unicode equivalent.

This is language-specific for performance reasons only.

Parameters:
$s string
Returns:
string

Reimplemented in LanguageAr, and LanguageMl.

Definition at line 2594 of file Language.php.

References $s, $wgAllUnicodeFixes, and UtfNormal::cleanUp().

Language::normalizeForSearch ( string  ) 

Some languages have special punctuation need to be normalized.

Make such changes here.

Parameters:
$string String
Returns:
String

Reimplemented in LanguageBe_tarask, LanguageYue, and LanguageZh_hans.

Definition at line 2435 of file Language.php.

Language::numLink ( Title title,
offset,
limit,
array $  query,
link,
tooltipMsg,
class 
) [private]

Helper function for viewPrevNext() that generates links.

Parameters:
$title Title object to link
$offset Integer offset parameter
$limit Integer limit parameter
$query Array extra query parameters
$link String text to use for the link; will be escaped
$tooltipMsg String name of the message to use as tooltip
$class String value of the "class" attribute of the link
Returns:
String HTML fragment

Definition at line 4121 of file Language.php.

References $limit, Html::element(), Title::getLocalURL(), and wfMessage().

Language::parseFormattedNumber ( number  ) 
Parameters:
$number string
Returns:
string

Definition at line 2862 of file Language.php.

References $s.

Language::pipeList ( array $  list  ) 

Same as commaList, but separate it with the pipe instead.

Parameters:
$list array of strings to put in a pipe list
Returns:
string

Definition at line 3016 of file Language.php.

References wfMsgExt().

Language::preConvertPlural ( forms,
count 
) [protected]

Checks that convertPlural was given an array and pads it to requested amount of forms by copying the last one.

Parameters:
$count Integer: How many forms should there be at least
$forms Array of forms given to convertPlural
Returns:
array Padded array of forms or an exception if not an array

Definition at line 3386 of file Language.php.

References $count.

Referenced by LanguageWa::convertPlural(), LanguageUk::convertPlural(), LanguageTl::convertPlural(), LanguageTi::convertPlural(), LanguageSr_el::convertPlural(), LanguageSr_ec::convertPlural(), LanguageSr::convertPlural(), LanguageSma::convertPlural(), LanguageSl::convertPlural(), LanguageSk::convertPlural(), LanguageSh::convertPlural(), LanguageSgs::convertPlural(), LanguageSe::convertPlural(), LanguageRu::convertPlural(), LanguageRo::convertPlural(), LanguagePl::convertPlural(), LanguageNso::convertPlural(), LanguageMt::convertPlural(), LanguageMo::convertPlural(), LanguageMk::convertPlural(), LanguageMg::convertPlural(), LanguageLv::convertPlural(), LanguageLt::convertPlural(), LanguageLn::convertPlural(), LanguageKsh::convertPlural(), LanguageHy::convertPlural(), LanguageHsb::convertPlural(), LanguageHr::convertPlural(), LanguageHi::convertPlural(), LanguageHe::convertPlural(), LanguageGv::convertPlural(), LanguageGd::convertPlural(), LanguageGa::convertPlural(), LanguageFr::convertPlural(), LanguageDsb::convertPlural(), LanguageCy::convertPlural(), LanguageCu::convertPlural(), LanguageCs::convertPlural(), LanguageBs::convertPlural(), LanguageBh::convertPlural(), LanguageBe_tarask::convertPlural(), LanguageBe::convertPlural(), LanguageAr::convertPlural(), and LanguageAm::convertPlural().

static Language::preloadLanguageClass ( class  )  [static]

Includes language class files.

Parameters:
$class string Name of the language class

Definition at line 268 of file Language.php.

References $IP.

Referenced by newFromCode().

Language::recodeForEdit ( s  ) 
Parameters:
$s string
Returns:
string

Definition at line 2552 of file Language.php.

References $s, and $wgEditEncoding.

Language::recodeInput ( s  ) 
Parameters:
$s string
Returns:
string

Definition at line 2568 of file Language.php.

References $s, and $wgEditEncoding.

Language::removeBadCharFirst ( string  )  [protected]

Remove bytes that represent an incomplete Unicode character at the start of string (e.g.

bytes of the char are missing)

Parameters:
$string String
Returns:
string

Definition at line 3115 of file Language.php.

Language::removeBadCharLast ( string  )  [protected]

Remove bytes that represent an incomplete Unicode character at the end of string (e.g.

bytes of the char are missing)

Parameters:
$string String
Returns:
string

Definition at line 3090 of file Language.php.

Language::replaceGrammarInNamespace ( m  ) 
Parameters:
$m string
Returns:
string

Definition at line 3835 of file Language.php.

static Language::romanNumeral ( num  )  [static]

Roman number formatting up to 3000.

Parameters:
$num int
Returns:
string

Definition at line 1645 of file Language.php.

References $s.

Language::segmentByWord ( string  ) 

Some languages such as Chinese require word segmentation, Specify such segmentation when overridden in derived class.

Parameters:
$string String
Returns:
String

Reimplemented in LanguageJa, LanguageYue, and LanguageZh_hans.

Definition at line 2424 of file Language.php.

Language::segmentForDiff ( text  ) 

languages like Chinese need to be segmented in order for the diff to be of any use

Parameters:
$text String
Returns:
String

Reimplemented in LanguageGan, and LanguageZh.

Definition at line 3434 of file Language.php.

Language::semicolonList ( array $  list  ) 

Take a list of strings and build a locale-friendly semicolon-separated list, using the local semicolon-separator message.

Parameters:
$list array of strings to put in a semicolon list
Returns:
string

Definition at line 3001 of file Language.php.

References wfMsgExt().

Language::separatorTransformTable (  ) 
Returns:
array

Definition at line 2948 of file Language.php.

Language::setCode ( code  ) 
Parameters:
$code string

Definition at line 3674 of file Language.php.

Language::setNamespaces ( array $  namespaces  ) 

Arbitrarily set all of the namespace names at once.

Mainly used for testing

Parameters:
$namespaces Array of namespaces (id => name)

Definition at line 393 of file Language.php.

Language::specialList ( page,
details,
oppositedm = true 
)

Make a list item, used by various special pages.

Parameters:
$page String Page link
$details String Text between brackets
$oppositedm Boolean Add the direction mark opposite to your language, to display text properly
Returns:
String

Definition at line 4059 of file Language.php.

References $page, and wfMsgExt().

Language::specialPage ( name  ) 
Parameters:
$name string
Returns:
string

Definition at line 591 of file Language.php.

Language::sprintfDate ( format,
ts 
)

This is a workalike of PHP's date() function, but with better internationalisation, a reduced set of format characters, and a better escaping format.

Supported format characters are dDjlNwzWFmMntLoYyaAgGhHiscrU. See the PHP manual for definitions. There are a number of extensions, which start with "x":

xn Do not translate digits of the next numeric format character xN Toggle raw digit (xn) flag, stays set until explicitly unset xr Use roman numerals for the next numeric format character xh Use hebrew numerals for the next numeric format character xx Literal x xg Genitive month name

xij j (day number) in Iranian calendar xiF F (month name) in Iranian calendar xin n (month number) in Iranian calendar xiy y (two digit year) in Iranian calendar xiY Y (full year) in Iranian calendar

xjj j (day number) in Hebrew calendar xjF F (month name) in Hebrew calendar xjt t (days in month) in Hebrew calendar xjx xg (genitive month name) in Hebrew calendar xjn n (month number) in Hebrew calendar xjY Y (full year) in Hebrew calendar

xmj j (day number) in Hijri calendar xmF F (month name) in Hijri calendar xmn n (month number) in Hijri calendar xmY Y (full year) in Hijri calendar

xkY Y (full year) in Thai solar calendar. Months and days are identical to the Gregorian calendar xoY Y (full year) in Minguo calendar or Juche year. Months and days are identical to the Gregorian calendar xtY Y (full year) in Japanese nengo. Months and days are identical to the Gregorian calendar

Characters enclosed in double quotes will be considered literal (with the quotes themselves removed). Unmatched quotes will be considered literal quotes. Example:

"The month is" F => The month is January i's" => 20'11"

Backslash escaping is also supported.

Input timestamp is assumed to be pre-normalized to the desired local time zone, if any.

Parameters:
$format String
$ts String: 14-character timestamp YYYYMMDDHHMMSS 01234567890123
Todo:
handling of "o" format character for Iranian, Hebrew, Hijri & Thai?
Returns:
string

Definition at line 948 of file Language.php.

Language::time ( ts,
adj = false,
format = true,
timecorrection = false 
)
Parameters:
$ts Mixed: the time format which needs to be turned into a date('YmdHis') format with wfTimestamp(TS_MW,$ts)
$adj Bool: whether to adjust the time output according to the user configured offset ($timecorrection)
$format Mixed: true to use user's date format preference
$timecorrection String|bool the time offset as returned by validateTimeZone() in Special:Preferences
Returns:
string

Definition at line 1898 of file Language.php.

References wfTimestamp().

Referenced by LanguageWa::timeanddate().

Language::timeanddate ( ts,
adj = false,
format = true,
timecorrection = false 
)
Parameters:
$ts Mixed: the time format which needs to be turned into a date('YmdHis') format with wfTimestamp(TS_MW,$ts)
$adj Bool: whether to adjust the time output according to the user configured offset ($timecorrection)
$format Mixed: what format to return, if it's false output the default one (default true)
$timecorrection String|bool the time offset as returned by validateTimeZone() in Special:Preferences
Returns:
string

Reimplemented in LanguageWa.

Definition at line 1918 of file Language.php.

References wfTimestamp().

Language::transformUsingPairFile ( file,
string 
)

Transform a string using serialized data stored in the given file (which must be in the serialized subdirectory of $IP).

The file contains pairs mapping source characters to destination characters.

The data is cached in process memory. This will go faster if you have the FastStringSearch extension.

Parameters:
$file string
$string string
Exceptions:
MWException 
Returns:
string

Definition at line 2619 of file Language.php.

References $file, and wfGetPrecompiledData().

Referenced by LanguageMl::normalize(), and LanguageAr::normalize().

Language::translateBlockExpiry ( str  ) 
Todo:
Maybe translate block durations. Note that this function is somewhat misnamed: it deals with translating the *duration* ("1 week", "4 days", etc), not the expiry time (which is an absolute timestamp). Please note: do NOT add this blindly, as it is used on old expiry lengths recorded in log entries. You'd need to provide the start date to match up with it.
Parameters:
$str String: the validated block duration in English
Returns:
string Somehow translated block duration
See also:
LanguageFi.php for example implementation

Definition at line 3404 of file Language.php.

References $value, and SpecialBlock::getSuggestedDurations().

Language::truncate ( string,
length,
ellipsis = '...',
adjustLength = true 
)

Truncate a string to a specified length in bytes, appending an optional string (e.g.

for ellipses)

The database offers limited byte lengths for some columns in the database; multi-byte character sets mean we need to ensure that only whole characters are included, otherwise broken characters can be passed to the user

If $length is negative, the string will be truncated from the beginning

Parameters:
$string String to truncate
$length Int: maximum length (including ellipses)
$ellipsis String to append to the truncated text
$adjustLength Boolean: Subtract length of ellipsis from $length. $adjustLength was introduced in 1.18, before that behaved as if false.
Returns:
string

Definition at line 3043 of file Language.php.

References wfMsgExt().

Language::truncate_endBracket ( &$  tag,
tagType,
lastCh,
&$  openTags 
) [private]

truncateHtml() helper function (a) push or pop $tag from $openTags as needed (b) clear $tag value

Parameters:
&$tag string Current HTML tag name we are looking at
$tagType int (0-open tag, 1-close tag)
$lastCh string Character before the '>' that ended this tag
&$openTags array Open tag stack (not accounting for $tag)

Definition at line 3280 of file Language.php.

Language::truncate_skip ( &$  ret,
text,
search,
start,
len = null 
) [private]

truncateHtml() helper function like strcspn() but adds the skipped chars to $ret

Parameters:
$ret 
$text 
$search 
$start 
$len 
Returns:
int

Definition at line 3257 of file Language.php.

Language::truncateHtml ( text,
length,
ellipsis = '...' 
)

Truncate a string of valid HTML to a specified length in bytes, appending an optional string (e.g.

for ellipses), and return valid HTML

This is only intended for styled/linked text, such as HTML with tags like and , were the tags are self-contained (valid HTML). Also, this will not detect things like "display:none" CSS.

Note: since 1.18 you do not need to leave extra room in $length for ellipses.

Parameters:
string $text HTML string to truncate
int $length (zero/positive) Maximum length (including ellipses)
string $ellipsis String to append to the truncated text
Returns:
string

Definition at line 3141 of file Language.php.

References wfMsgExt().

static Language::tsToHebrew ( ts  )  [static, private]

Converting Gregorian dates to Hebrew dates.

Based on a JavaScript code by Abu Mami and Yisrael Hersch ([email protected], http://www.kaluach.net), who permitted to translate the relevant functions into PHP and release them under GNU GPL.

The months are counted from Tishrei = 1. In a leap year, Adar I is 13 and Adar II is 14. In a non-leap year, Adar is 6.

Parameters:
$ts string
Returns:
string

Definition at line 1387 of file Language.php.

static Language::tsToHijri ( ts  )  [static, private]

Converting Gregorian dates to Hijri dates.

Based on a PHP-Nuke block by Sharjeel which is released under GNU/GPL license

See also:
http://phpnuke.org/modules.php?name=News&file=article&sid=8234&mode=thread&order=0&thold=0
Parameters:
$ts string
Returns:
string

Definition at line 1336 of file Language.php.

static Language::tsToIranian ( ts  )  [static, private]

Algorithm by Roozbeh Pournader and Mohammad Toossi to convert Gregorian dates to Iranian dates.

Originally written in C, it is released under the terms of GNU Lesser General Public License. Conversion to PHP was performed by Niklas Laxström.

Link: http://www.farsiweb.info/jalali/jalali.c

Parameters:
$ts string
Returns:
string

Definition at line 1278 of file Language.php.

static Language::tsToYear ( ts,
cName 
) [static, private]

Algorithm to convert Gregorian dates to Thai solar dates, Minguo dates or Minguo dates.

Link: http://en.wikipedia.org/wiki/Thai_solar_calendar http://en.wikipedia.org/wiki/Minguo_calendar http://en.wikipedia.org/wiki/Japanese_era_name

Parameters:
$ts String: 14-character timestamp
$cName String: calender name
Returns:
Array: converted year, month, day

Definition at line 1566 of file Language.php.

Language::uc ( str,
first = false 
)

Convert a string to uppercase.

Parameters:
$str string
$first bool
Returns:
string

Definition at line 2207 of file Language.php.

Language::ucCallback ( matches  ) 
Parameters:
$matches array
Returns:
string

Definition at line 2149 of file Language.php.

References $matches, and $wikiUpperChars.

Language::ucfirst ( str  ) 

Make a string's first character uppercase.

Parameters:
$str string
Returns:
string

Reimplemented in LanguageAz, LanguageKaa, LanguageKk, and LanguageTr.

Definition at line 2187 of file Language.php.

Referenced by classFromCode().

Language::ucwordbreaks ( str  ) 

capitalize words at word breaks

Parameters:
$str string
Returns:
mixed

Definition at line 2324 of file Language.php.

Language::ucwordbreaksCallbackAscii ( matches  ) 
Parameters:
$matches array
Returns:
mixed|string

Definition at line 2133 of file Language.php.

References $matches.

Language::ucwordbreaksCallbackMB ( matches  ) 
Parameters:
$matches array
Returns:
string

Definition at line 2141 of file Language.php.

References $matches.

Language::ucwords ( str  ) 
Parameters:
$str string
Returns:
mixed|string

Definition at line 2292 of file Language.php.

Language::ucwordsCallbackMB ( matches  ) 
Parameters:
$matches array
Returns:
string

Definition at line 2167 of file Language.php.

References $matches.

Language::ucwordsCallbackWiki ( matches  ) 
Parameters:
$matches array
Returns:
string

Definition at line 2175 of file Language.php.

References $matches, and $wikiUpperChars.

Language::unsegmentForDiff ( text  ) 

and unsegment to show the result

Parameters:
$text String
Returns:
String

Reimplemented in LanguageGan, and LanguageZh.

Definition at line 3444 of file Language.php.

Language::userAdjust ( ts,
tz = false 
)

Used by date() and time() to adjust the time output.

Parameters:
$ts Int the time in date('YmdHis') format
$tz Mixed: adjust the time by this amount (default false, mean we get user timecorrection setting)
Returns:
int

Definition at line 1739 of file Language.php.

References $t, $wgLocalTZoffset, $wgUser, wfRestoreWarnings(), and wfSuppressWarnings().

Referenced by LanguageWa::date(), and LanguageWa::timeanddate().

Language::userDate ( ts,
User user,
array $  options = array() 
)

Get the formatted date for the given timestamp and formatted for the given user.

Parameters:
$ts Mixed: the time format which needs to be turned into a date('YmdHis') format with wfTimestamp(TS_MW,$ts)
$user User object used to get preferences for timezone and format
$options Array, can contain the following keys:

  • 'timecorrection': time correction, can have the following values:
    • true: use user's preference
    • false: don't use time correction
    • integer: value of time correction in minutes
  • 'format': format to use, can have the following values:
    • true: use user's preference
    • false: use default preference
    • string: format to use
Since:
1.19
Returns:
String

Definition at line 2042 of file Language.php.

References $options.

Language::userTime ( ts,
User user,
array $  options = array() 
)

Get the formatted time for the given timestamp and formatted for the given user.

Parameters:
$ts Mixed: the time format which needs to be turned into a date('YmdHis') format with wfTimestamp(TS_MW,$ts)
$user User object used to get preferences for timezone and format
$options Array, can contain the following keys:

  • 'timecorrection': time correction, can have the following values:
    • true: use user's preference
    • false: don't use time correction
    • integer: value of time correction in minutes
  • 'format': format to use, can have the following values:
    • true: use user's preference
    • false: use default preference
    • string: format to use
Since:
1.19
Returns:
String

Definition at line 2065 of file Language.php.

References $options.

Language::userTimeAndDate ( ts,
User user,
array $  options = array() 
)

Get the formatted date and time for the given timestamp and formatted for the given user.

Parameters:
$ts Mixed: the time format which needs to be turned into a date('YmdHis') format with wfTimestamp(TS_MW,$ts)
$user User object used to get preferences for timezone and format
$options Array, can contain the following keys:

  • 'timecorrection': time correction, can have the following values:
    • true: use user's preference
    • false: don't use time correction
    • integer: value of time correction in minutes
  • 'format': format to use, can have the following values:
    • true: use user's preference
    • false: use default preference
    • string: format to use
Since:
1.19
Returns:
String

Definition at line 2088 of file Language.php.

References $options.

Language::viewPrevNext ( Title title,
offset,
limit,
array $  query = array(),
atend = false 
)

Generate (prev x| next x) (20|50|100.

..) type links for paging

Parameters:
$title Title object to link
$offset Integer offset parameter
$limit Integer limit parameter
$query String optional URL query parameter string
$atend Bool optional param for specified if this is the last page
Returns:
String

Definition at line 4077 of file Language.php.

References $limit, and wfMessage().


Member Data Documentation

Language::$dataCache [static]

Definition at line 84 of file Language.php.

Language::$dateFormatStrings = array()

Definition at line 71 of file Language.php.

Language::$durationIntervals [static]
Initial value:
 array(
                'millennia' => 31557600000,
                'centuries' => 3155760000,
                'decades' => 315576000,
                'years' => 31557600, 
                'weeks' => 604800,
                'days' => 86400,
                'hours' => 3600,
                'minutes' => 60,
                'seconds' => 1,
        )

Definition at line 146 of file Language.php.

Language::$GREG_DAYS = array( 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 ) [static, private]

Definition at line 1263 of file Language.php.

Language::$IRANIAN_DAYS = array( 31, 31, 31, 31, 31, 31, 30, 30, 30, 30, 30, 29 ) [static, private]

Definition at line 1264 of file Language.php.

Language::$mCode

Definition at line 67 of file Language.php.

Language::$mConverter

Definition at line 65 of file Language.php.

Language::$mExtendedSpecialPageAliases

Definition at line 72 of file Language.php.

Language::$mHebrewCalendarMonthGenMsgs [static]
Initial value:
 array(
                'hebrew-calendar-m1-gen', 'hebrew-calendar-m2-gen', 'hebrew-calendar-m3-gen',
                'hebrew-calendar-m4-gen', 'hebrew-calendar-m5-gen', 'hebrew-calendar-m6-gen',
                'hebrew-calendar-m7-gen', 'hebrew-calendar-m8-gen', 'hebrew-calendar-m9-gen',
                'hebrew-calendar-m10-gen', 'hebrew-calendar-m11-gen', 'hebrew-calendar-m12-gen',
                'hebrew-calendar-m6a-gen', 'hebrew-calendar-m6b-gen'
        )

Definition at line 127 of file Language.php.

Language::$mHebrewCalendarMonthMsgs [static]
Initial value:
 array(
                'hebrew-calendar-m1', 'hebrew-calendar-m2', 'hebrew-calendar-m3',
                'hebrew-calendar-m4', 'hebrew-calendar-m5', 'hebrew-calendar-m6',
                'hebrew-calendar-m7', 'hebrew-calendar-m8', 'hebrew-calendar-m9',
                'hebrew-calendar-m10', 'hebrew-calendar-m11', 'hebrew-calendar-m12',
                'hebrew-calendar-m6a', 'hebrew-calendar-m6b'
        )

Definition at line 119 of file Language.php.

Language::$mHijriCalendarMonthMsgs [static]
Initial value:
 array(
                'hijri-calendar-m1', 'hijri-calendar-m2', 'hijri-calendar-m3',
                'hijri-calendar-m4', 'hijri-calendar-m5', 'hijri-calendar-m6',
                'hijri-calendar-m7', 'hijri-calendar-m8', 'hijri-calendar-m9',
                'hijri-calendar-m10', 'hijri-calendar-m11', 'hijri-calendar-m12'
        )

Definition at line 135 of file Language.php.

Language::$mHtmlCode = null [private]

Definition at line 69 of file Language.php.

Language::$mIranianCalendarMonthMsgs [static]
Initial value:
 array(
                'iranian-calendar-m1', 'iranian-calendar-m2', 'iranian-calendar-m3',
                'iranian-calendar-m4', 'iranian-calendar-m5', 'iranian-calendar-m6',
                'iranian-calendar-m7', 'iranian-calendar-m8', 'iranian-calendar-m9',
                'iranian-calendar-m10', 'iranian-calendar-m11', 'iranian-calendar-m12'
        )

Definition at line 112 of file Language.php.

Language::$mLangObjCache = array() [static]

Definition at line 86 of file Language.php.

Language::$mLoaded = false

Definition at line 67 of file Language.php.

Language::$mMagicExtensions = array()

Definition at line 68 of file Language.php.

Language::$mMagicHookDone = false

Definition at line 68 of file Language.php.

Language::$mMonthAbbrevMsgs [static]
Initial value:
 array(
                'jan', 'feb', 'mar', 'apr', 'may', 'jun', 'jul', 'aug',
                'sep', 'oct', 'nov', 'dec'
        )

Definition at line 107 of file Language.php.

Language::$mMonthGenMsgs [static]
Initial value:
 array(
                'january-gen', 'february-gen', 'march-gen', 'april-gen', 'may-gen', 'june-gen',
                'july-gen', 'august-gen', 'september-gen', 'october-gen', 'november-gen',
                'december-gen'
        )

Definition at line 102 of file Language.php.

Language::$mMonthMsgs [static]
Initial value:
 array(
                'january', 'february', 'march', 'april', 'may_long', 'june',
                'july', 'august', 'september', 'october', 'november',
                'december'
        )

Definition at line 97 of file Language.php.

Language::$mNamespaceIds [protected]

Definition at line 74 of file Language.php.

Language::$mVariants

Definition at line 67 of file Language.php.

Language::$mWeekdayAbbrevMsgs [static]
Initial value:
 array(
                'sun', 'mon', 'tue', 'wed', 'thu', 'fri', 'sat'
        )

Definition at line 93 of file Language.php.

Language::$mWeekdayMsgs [static]
Initial value:
 array(
                'sunday', 'monday', 'tuesday', 'wednesday', 'thursday',
                'friday', 'saturday'
        )

Definition at line 88 of file Language.php.

Language::$namespaceAliases [protected]

Definition at line 74 of file Language.php.

Language::$namespaceNames [protected]

Definition at line 74 of file Language.php.

Language::$transformData = array()

ReplacementArray object caches.

Definition at line 79 of file Language.php.


The documentation for this class was generated from the following file:
Generated on Thu Apr 19 00:00:41 2012 for MediaWiki by  doxygen 1.6.3