| Total Complexity | 4 |
| Total Lines | 37 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php declare(strict_types=1); |
||
| 21 | class Csv implements CsvInterface |
||
| 22 | { |
||
| 23 | protected $delimiter = Delimiter::DELIMITER_COMMA; |
||
| 24 | protected $enclosure = Enclosure::ENCLOSURE_DOUBLE_QUOTE; |
||
| 25 | protected $newline = Newline::NEWLINE_LF; |
||
| 26 | protected $escape = Escape::ESCAPE_CHAR; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * @param string $delimiter |
||
| 30 | */ |
||
| 31 | 1 | public function setDelimiter(string $delimiter) |
|
| 32 | { |
||
| 33 | 1 | $this->delimiter = $delimiter; |
|
| 34 | 1 | } |
|
| 35 | |||
| 36 | /** |
||
| 37 | * @param string $enclosure |
||
| 38 | */ |
||
| 39 | 1 | public function setEnclosure(string $enclosure) |
|
| 40 | { |
||
| 41 | 1 | $this->enclosure = $enclosure; |
|
| 42 | 1 | } |
|
| 43 | |||
| 44 | /** |
||
| 45 | * @param string $newline |
||
| 46 | */ |
||
| 47 | 1 | public function setNewline(string $newline) |
|
| 48 | { |
||
| 49 | 1 | $this->newline = $newline; |
|
| 50 | 1 | } |
|
| 51 | |||
| 52 | /** |
||
| 53 | * @param string $escape |
||
| 54 | */ |
||
| 55 | 1 | public function setEscape(string $escape) |
|
| 58 | 1 | } |
|
| 59 | } |
||
| 60 |