Skip to content

Commit a3bedc3

Browse files
committed
Translator: Basic translator, now returning input only
1 parent 8de55db commit a3bedc3

File tree

2 files changed

+19
-0
lines changed

2 files changed

+19
-0
lines changed

config.neon

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
services:
22
- Mathematicator\Engine\Engine
33
- Mathematicator\Engine\QueryNormalizer
4+
- Mathematicator\Engine\Translator
45
- Model\Math\NumberRewriter
56

67
orm.annotations:

src/Translator.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace Mathematicator\Engine;
6+
7+
8+
use Nette\Localization\ITranslator;
9+
10+
class Translator implements ITranslator
11+
{
12+
13+
public function translate($message, ...$parameters): string
14+
{
15+
return (string) $message;
16+
}
17+
18+
}

0 commit comments

Comments
 (0)