Total Complexity | 5 |
Total Lines | 55 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 1 | ||
Bugs | 1 | Features | 0 |
1 | <?php |
||
5 | class FormatLine |
||
6 | { |
||
7 | /** |
||
8 | * |
||
9 | * @var array |
||
10 | */ |
||
11 | private static $strict = []; |
||
12 | |||
13 | /** |
||
14 | * Format |
||
15 | * |
||
16 | * @param string $format |
||
17 | * @return StrictQuoteLine |
||
18 | */ |
||
19 | 12 | public static function strictQuote($format) |
|
26 | } |
||
27 | |||
28 | /** |
||
29 | * Array in a string for a query Insert |
||
30 | * |
||
31 | * @param mixed[] $row |
||
32 | * @param bool $skipEncode |
||
33 | * @return string |
||
34 | */ |
||
35 | 12 | public static function Insert(array $row,bool $skipEncode=false) |
|
36 | { |
||
37 | 12 | return self::strictQuote('Insert')->quoteRow($row,$skipEncode); |
|
38 | } |
||
39 | |||
40 | /** |
||
41 | * Array to TSV |
||
42 | * |
||
43 | * @param array $row |
||
44 | * @return string |
||
45 | */ |
||
46 | 1 | public static function TSV(Array $row) |
|
47 | { |
||
48 | 1 | return self::strictQuote('TSV')->quoteRow($row); |
|
49 | } |
||
50 | |||
51 | /** |
||
52 | * Array to CSV |
||
53 | * |
||
54 | * @param array $row |
||
55 | * @return string |
||
56 | */ |
||
57 | 1 | public static function CSV(Array $row) |
|
60 | } |
||
61 | } |
||
62 |