TranslationService
        TranslationService.php
                :
        20
                 
    
            Interface
                Interface for a translation service.
Implement this to use translation backends like Symfony2 Translate, gettext or ezcTranslation.
Call the translation method with the current target locale from your templates, for example.
Methods¶
                 translate()
            ¶
translate()
            ¶
    
        
        TranslationService.php
                :
        32
                 
    
        Translate.
|  |  | 
Translate a Translation value object.
Parameters
| Name | Type | Default value | Description | 
|---|---|---|---|
| $translation | Translation | - | - | 
| $locale | string | - | - | 
Return values
string
                 translateString()
            ¶
translateString()
            ¶
    
        
        TranslationService.php
                :
        45
                 
    
        Translate string.
|  |  | 
Translate a string. Strings could be useful for the simplest cases. Usually you will always use Translation value objects for this.
Parameters
| Name | Type | Default value | Description | 
|---|---|---|---|
| $translation | string | - | - | 
| $locale | string | - | - | 
Return values
string