blob: 1f9aab23bb90fbf30a09fb68850808dc5ef607a0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
<?php
namespace ipl\I18n;
use ipl\Stdlib\Contract\Translator;
/**
* Translator that just returns the original messages
*/
class NoopTranslator implements Translator
{
public function translate($message, $context = null)
{
return $message;
}
public function translateInDomain($domain, $message, $context = null)
{
return $message;
}
public function translatePlural($singular, $plural, $number, $context = null)
{
return $number === 1 ? $singular : $plural;
}
public function translatePluralInDomain($domain, $singular, $plural, $number, $context = null)
{
return $number === 1 ? $singular : $plural;
}
}
|