1 | <?php |
||
14 | trait TripletTransformer |
||
15 | { |
||
16 | /** |
||
17 | * Chuyển đổi cụm 3 số thành chữ số. |
||
18 | * |
||
19 | * @param int $triplet |
||
20 | * @param bool $isFirst |
||
21 | * @param int $exponent |
||
22 | * @return string |
||
23 | */ |
||
24 | protected function tripletToWords(int $triplet, bool $isFirst, int $exponent): string |
||
48 | |||
49 | /** |
||
50 | * Chia 3 số thành mảng 3 phần tử tương ứng với hàng trăm, hàng chục, hàng đơn vị. |
||
51 | * |
||
52 | * @param int $triplet |
||
53 | * @return array |
||
54 | */ |
||
55 | private function splitTriplet(int $triplet): array |
||
63 | |||
64 | /** |
||
65 | * Chuyển đổi số hàng đơn vị sang chữ số ở một số trường hợp đặc biệt. |
||
66 | * |
||
67 | * @param int $unit |
||
68 | * @param int $ten |
||
69 | * @return null|string |
||
70 | */ |
||
71 | private function getTripletUnit(int $unit, int $ten): string |
||
89 | } |
||
90 |
This check marks access to variables or properties that have not been declared yet. While PHP has no explicit notion of declaring a variable, accessing it before a value is assigned to it is most likely a bug.