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

ShowPhoneTranslation   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 5
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
eloc 2
c 1
b 0
f 0
dl 0
loc 5
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A translate() 0 3 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