Passed
Push — master ( d8dc61...dfdb64 )
by Sebastian
09:05
created

ShowPhoneTranslation::translate()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 1
c 1
b 0
f 0
dl 0
loc 3
rs 10
cc 1
nc 1
nop 1
1
<?php
2
/**
3
 * File containing the {@see \Mailcode\Translator\Syntax\ApacheVelocity\ShowPhoneTranslation} class.
4
 *
5
 * @package Mailcode
6
 * @subpackage Translator
7
 * @see \Mailcode\Translator\Syntax\ApacheVelocity\ShowPhoneTranslation
8
 */
9
10
declare(strict_types=1);
11
12
namespace Mailcode\Translator\Syntax\HubL;
13
14
use Mailcode\Mailcode_Commands_Command_ShowPhone;
15
use Mailcode\Mailcode_Translator_Command_ShowPhone;
16
use Mailcode\Translator\Syntax\HubL;
17
18
/**
19
 * Translates the {@see Mailcode_Commands_Command_ShowPhone} command to HubL.
20
 *
21
 * @package Mailcode
22
 * @subpackage Translator
23
 * @author Sebastian Mordziol <[email protected]>
24
 */
25
class ShowPhoneTranslation extends HubL implements Mailcode_Translator_Command_ShowPhone
26
{
27
    public function translate(Mailcode_Commands_Command_ShowPhone $command): string
28
    {
29
        return '{{ ' . $command->getVariableName() . ' }}';
30
    }
31
}
32