\Cake\ORM\Behavior\TranslateTranslateTrait

Contains a translation method aimed to help managing multiple translations for an entity.

Summary

Methods
Properties
Constants
translation()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
No private properties found
N/A

Methods

translation()

translation(string  $language) : $this|\Cake\Datasource\EntityInterface

Returns the entity containing the translated fields for this object and for the specified language. If the translation for the passed language is not present, a new empty entity will be created so that values can be added to it.

Parameters

string $language

Language to return entity for.

Returns

$this|\Cake\Datasource\EntityInterface