1 | <?php |
||
12 | class CsvWriter extends AbstractStreamWriter |
||
13 | { |
||
14 | /** |
||
15 | * @var string |
||
16 | */ |
||
17 | private $delimiter = ';'; |
||
18 | |||
19 | /** |
||
20 | * @var string |
||
21 | */ |
||
22 | private $enclosure = '"'; |
||
23 | |||
24 | /** |
||
25 | * @var bool |
||
26 | */ |
||
27 | private $utf8Encoding = false; |
||
28 | private $row = 1; |
||
29 | |||
30 | /** |
||
31 | * @var bool |
||
32 | */ |
||
33 | protected $prependHeaderRow; |
||
34 | |||
35 | /** |
||
36 | * @param string $delimiter The delimiter |
||
37 | * @param string $enclosure The enclosure |
||
38 | * @param resource $stream |
||
39 | * @param bool $utf8Encoding |
||
40 | */ |
||
41 | 3 | public function __construct($delimiter = ';', $enclosure = '"', $stream = null, $utf8Encoding = false, $prependHeaderRow = false) |
|
51 | |||
52 | /** |
||
53 | * {@inheritdoc} |
||
54 | */ |
||
55 | 3 | public function prepare() |
|
61 | |||
62 | /** |
||
63 | * {@inheritdoc} |
||
64 | */ |
||
65 | 3 | public function writeItem(array $item) |
|
74 | } |
||
75 |