This class implements default behavior for file based message groups. More...
Public Member Functions | |
| getFFS () | |
| exists () | |
| @inheritDoc | |
| load ( $code) | |
| @inheritDoc | |
| parseExternal (string $code) | |
| getSourceFilePath ( $code) | |
| getTargetFilename (string $code) | |
| replaceVariables ( $pattern, $code) | |
| mapCode ( $code) | |
| getKeys () | |
| @inheritDoc | |
| initCollection ( $code) | |
| @inheritDoc | |
| getMessage ( $key, $code) | |
| @inheritDoc | |
| getMessageGroupCache (string $code) | |
| getSourceLanguage () | |
| Returns language code depicting the language of source text. | |
Public Member Functions inherited from MessageGroupBase | |
| getConfiguration () | |
| getId () | |
| @inheritDoc | |
| getLabel (?IContextSource $context=null) | |
| @inheritDoc | |
| getDescription (?IContextSource $context=null) | |
| @inheritDoc | |
| getIcon () | |
| @inheritDoc | |
| getNamespace () | |
| @inheritDoc | |
| isMeta () | |
| @inheritDoc | |
| getDefinitions () | |
| @inheritDoc | |
| getValidator () | |
| @inheritDoc | |
| getMangler () | |
| @inheritDoc | |
| getInsertablesSuggester () | |
| Returns the configured InsertablesSuggester if any. | |
| getTags ( $type=null) | |
| @inheritDoc | |
| getMessageGroupStates () | |
| @inheritDoc | |
| getTranslatableLanguages () | |
| @inheritDoc | |
| getSupportConfig () | |
| @inheritDoc | |
| getRelatedPage () | |
| @inheritDoc | |
Static Public Member Functions | |
| static | newFromMessageGroup (MessageGroup $group, string $targetPattern='') |
| Constructs a FileBasedMessageGroup from any normal message group. | |
| static | getExtraSchema () |
| Return a data structure that will be merged with the base schema. | |
Static Public Member Functions inherited from MessageGroupBase | |
| static | factory (array $conf) |
Public Attributes | |
| const | NO_FILE_FORMAT = 1 |
Public Attributes inherited from MessageGroup | |
| const | DEFAULT_LANGUAGES = null |
| Return value from getTranslatableLanguages when to use defaults. | |
Protected Attributes | |
| $reverseCodeMap | |
Protected Attributes inherited from MessageGroupBase | |
| array | $conf |
| int | $namespace |
| StringMatcher | $mangler = null |
Additional Inherited Members | |
Protected Member Functions inherited from MessageGroupBase | |
| parseTags (array $patterns) | |
| getRawTags (?string $type=null) | |
| setTags (MessageCollection $collection) | |
| parseNamespace () | |
| isSourceLanguage (string $code) | |
This class implements default behavior for file based message groups.
File based message groups are primary type of groups at translatewiki.net, while other projects may use mainly page translation message groups, or custom type of message groups.
Definition at line 27 of file FileBasedMessageGroup.php.
| FileBasedMessageGroup::exists | ( | ) |
|
static |
Return a data structure that will be merged with the base schema.
It is not possible to remove things.
Implements MediaWiki\Extension\Translate\MessageGroupConfiguration\MetaYamlSchemaExtender.
Definition at line 203 of file FileBasedMessageGroup.php.
| FileBasedMessageGroup::getFFS | ( | ) |
Definition at line 66 of file FileBasedMessageGroup.php.
| FileBasedMessageGroup::getKeys | ( | ) |
@inheritDoc
Reimplemented from MessageGroupBase.
Definition at line 242 of file FileBasedMessageGroup.php.
| FileBasedMessageGroup::getMessage | ( | $key, | |
| $code ) |
| FileBasedMessageGroup::getMessageGroupCache | ( | string | $code | ) |
Definition at line 296 of file FileBasedMessageGroup.php.
| FileBasedMessageGroup::getSourceFilePath | ( | $code | ) |
| string | $code | Language code. |
Definition at line 118 of file FileBasedMessageGroup.php.
| FileBasedMessageGroup::getSourceLanguage | ( | ) |
Returns language code depicting the language of source text.
Implements MessageGroup.
Definition at line 304 of file FileBasedMessageGroup.php.
| FileBasedMessageGroup::getTargetFilename | ( | string | $code | ) |
Definition at line 134 of file FileBasedMessageGroup.php.
| FileBasedMessageGroup::initCollection | ( | $code | ) |
| FileBasedMessageGroup::load | ( | $code | ) |
| FileBasedMessageGroup::mapCode | ( | $code | ) |
| string | $code | Language code. |
Definition at line 183 of file FileBasedMessageGroup.php.
|
static |
Constructs a FileBasedMessageGroup from any normal message group.
Useful for doing special Gettext exports from any group.
| MessageGroup | $group | |
| string | $targetPattern | Value for FILES.targetPattern |
Definition at line 40 of file FileBasedMessageGroup.php.
| FileBasedMessageGroup::parseExternal | ( | string | $code | ) |
| string | $code | Language tag. |
Definition at line 100 of file FileBasedMessageGroup.php.
| FileBasedMessageGroup::replaceVariables | ( | $pattern, | |
| $code ) |
| string | $pattern | |
| string | $code | Language code. |
Definition at line 166 of file FileBasedMessageGroup.php.
|
protected |
Definition at line 31 of file FileBasedMessageGroup.php.
| const FileBasedMessageGroup::NO_FILE_FORMAT = 1 |
Definition at line 28 of file FileBasedMessageGroup.php.