Class humhub\commands\MessageController

Inheritancehumhub\commands\MessageController » yii\console\controllers\MessageController

Extracts messages to be translated from source files.

Public Methods

Hide inherited methods

MethodDescriptionDefined By
actionBuildArchive() Collects all translated strings and stores it in a archive.json file. humhub\commands\MessageController
actionExtractModule() Extracts messages for a given module from source code. humhub\commands\MessageController

Protected Methods

Hide inherited methods

MethodDescriptionDefined By
getModuleByCategory() Returns module instance by given message category. humhub\commands\MessageController
saveMessagesToPHP() humhub\commands\MessageController

Method Details

actionBuildArchive() public method

Collects all translated strings and stores it in a archive.json file.

public void actionBuildArchive ( )
actionExtractModule() public method

Extracts messages for a given module from source code.

public void actionExtractModule ( $moduleId )
$moduleId string
getModuleByCategory() protected method

Returns module instance by given message category.

protected \yii\base\Module getModuleByCategory ( $category )
$category string
saveMessagesToPHP() protected method

protected void saveMessagesToPHP ( $messages, $dirName, $overwrite, $removeUnused, $sort, $markUnused )
$messages
$dirName
$overwrite
$removeUnused
$sort
$markUnused