1 | <?php |
||
16 | class Languagefile |
||
17 | { |
||
18 | /** |
||
19 | * The path on the local file system. |
||
20 | * @var string |
||
21 | */ |
||
22 | protected $localPath; |
||
23 | |||
24 | /** |
||
25 | * The path at crowdin. |
||
26 | * @var string |
||
27 | */ |
||
28 | protected $crowdinPath; |
||
29 | |||
30 | /** |
||
31 | * The language file title. |
||
32 | * @var string |
||
33 | */ |
||
34 | protected $title; |
||
35 | |||
36 | /** |
||
37 | * The export pattern. |
||
38 | * @var string |
||
39 | */ |
||
40 | protected $exportPattern; |
||
41 | |||
42 | /** |
||
43 | * Constructor. |
||
44 | * |
||
45 | * @param string $localPath The path on the local file system. |
||
46 | * @param string $crowdinPath The path on Crowdin. |
||
47 | */ |
||
48 | 1 | public function __construct(string $localPath, string $crowdinPath) |
|
58 | |||
59 | /** |
||
60 | * Get the local path. |
||
61 | * |
||
62 | * @return string |
||
63 | */ |
||
64 | 1 | public function getLocalPath() : string |
|
65 | { |
||
66 | 1 | return $this->localPath ?: ''; |
|
67 | } |
||
68 | |||
69 | /** |
||
70 | * Get the Crowdin path. |
||
71 | * |
||
72 | * @return string |
||
73 | */ |
||
74 | 1 | public function getCrowdinPath() : string |
|
78 | |||
79 | /** |
||
80 | * Set the export pattern. |
||
81 | * |
||
82 | * @param string $exportPattern The export pattern. |
||
83 | * |
||
84 | * @return $this |
||
85 | */ |
||
86 | 1 | public function setExportPattern(string $exportPattern) |
|
92 | |||
93 | /** |
||
94 | * Get the export pattern. |
||
95 | * |
||
96 | * @return string |
||
97 | */ |
||
98 | 1 | public function getExportPattern() : string |
|
99 | { |
||
100 | 1 | return $this->exportPattern ?: ''; |
|
101 | } |
||
102 | |||
103 | /** |
||
104 | * Set the title. |
||
105 | * |
||
106 | * @param string $title The title. |
||
107 | * |
||
108 | * @return $this |
||
109 | */ |
||
110 | 1 | public function setTitle(string $title) |
|
116 | |||
117 | /** |
||
118 | * Get the title. |
||
119 | * |
||
120 | * @return string |
||
121 | */ |
||
122 | 1 | public function getTitle() : string |
|
126 | } |
||
127 |