HasIndoEuropeanVerboseMethods   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 46
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 5

Importance

Changes 0
Metric Value
wmc 3
lcom 1
cbo 5
dl 0
loc 46
rs 10
c 0
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A inAlbanian() 0 4 1
A inArmenian() 0 4 1
A inGreek() 0 4 1
1
<?php
2
3
namespace ChinLeung\VerboseLocalization\Concerns;
4
5
trait HasIndoEuropeanVerboseMethods
6
{
7
    use HasBaltoSlavicVerboseMethods,
8
        HasCelticVerboseMethods,
9
        HasGermanicVerboseMethods,
10
        HasIndoIranianVerboseMethods,
11
        HasItalicVerboseMethods;
12
13
    /**
14
     * Retrieve the translation in another locale.
15
     *
16
     * @param  string  $locale
17
     * @return mixed
18
     */
19
    abstract public function getTranslationIn(string $locale);
20
21
    /**
22
     * Function to retrieve the translation in Albanian.
23
     *
24
     * @return mixed
25
     */
26
    public function inAlbanian()
27
    {
28
        return $this->getTranslationIn('sq');
29
    }
30
31
    /**
32
     * Function to retrieve the translation in Armenian.
33
     *
34
     * @return mixed
35
     */
36
    public function inArmenian()
37
    {
38
        return $this->getTranslationIn('hy');
39
    }
40
41
    /**
42
     * Function to retrieve the translation in Greek.
43
     *
44
     * @return mixed
45
     */
46
    public function inGreek()
47
    {
48
        return $this->getTranslationIn('el');
49
    }
50
}
51