PHP Class Cake\Upgrade\Shell\Task\I18nTask

Updates __() calls.
Inheritance: extends BaseTask, use trait ChangeTrait
Show file Open project: cakephp/upgrade

Public Properties

Property Type Description
$tasks

Protected Methods

Method Description
_adjustI18n ( string $contents ) : string Adjusts __() to use {n} instead of %s.
_process ( $path ) : void Converts placeholders from 2.x to 3.x syntax.
_shouldProcess ( string $path ) : boolean _shouldProcess

Method Details

_adjustI18n() protected method

Adjusts __() to use {n} instead of %s.
protected _adjustI18n ( string $contents ) : string
$contents string
return string

_process() protected method

Converts placeholders from 2.x to 3.x syntax.
protected _process ( $path ) : void
return void

_shouldProcess() protected method

Bail for invalid files (php/ctp files only)
protected _shouldProcess ( string $path ) : boolean
$path string
return boolean

Property Details

$tasks public property

public $tasks