Commit 1e38ed083e661ec8c531dc02e2858087814483a3
1 parent
1e991822
delete harnica csv parser
Showing
11 changed files
with
0 additions
and
1453 deletions
Show diff stats
vendor/hranicka/csv/.gitignore deleted
vendor/hranicka/csv/composer.json deleted
1 | -{ | |
2 | - "name": "hranicka/csv", | |
3 | - "description": "CSV parser", | |
4 | - "license": ["MIT"], | |
5 | - "authors": [ | |
6 | - { | |
7 | - "name": "Jaroslav Hranička", | |
8 | - "email": "hranicka@outlook.com" | |
9 | - } | |
10 | - ], | |
11 | - "require": { | |
12 | - "php": ">=5.4.0" | |
13 | - }, | |
14 | - "require-dev": { | |
15 | - "phpunit/phpunit": "~4.3", | |
16 | - "mikey179/vfsStream": "~1.5.0" | |
17 | - }, | |
18 | - "autoload": { | |
19 | - "psr-4": {"Hranicka\\Csv\\": "src/"} | |
20 | - } | |
21 | -} |
vendor/hranicka/csv/composer.lock deleted
1 | -{ | |
2 | - "_readme": [ | |
3 | - "This file locks the dependencies of your project to a known state", | |
4 | - "Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", | |
5 | - "This file is @generated automatically" | |
6 | - ], | |
7 | - "hash": "82886b29d4ea2277b502de997dc38bc7", | |
8 | - "packages": [], | |
9 | - "packages-dev": [ | |
10 | - { | |
11 | - "name": "doctrine/instantiator", | |
12 | - "version": "1.0.4", | |
13 | - "source": { | |
14 | - "type": "git", | |
15 | - "url": "https://github.com/doctrine/instantiator.git", | |
16 | - "reference": "f976e5de371104877ebc89bd8fecb0019ed9c119" | |
17 | - }, | |
18 | - "dist": { | |
19 | - "type": "zip", | |
20 | - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/f976e5de371104877ebc89bd8fecb0019ed9c119", | |
21 | - "reference": "f976e5de371104877ebc89bd8fecb0019ed9c119", | |
22 | - "shasum": "" | |
23 | - }, | |
24 | - "require": { | |
25 | - "php": ">=5.3,<8.0-DEV" | |
26 | - }, | |
27 | - "require-dev": { | |
28 | - "athletic/athletic": "~0.1.8", | |
29 | - "ext-pdo": "*", | |
30 | - "ext-phar": "*", | |
31 | - "phpunit/phpunit": "~4.0", | |
32 | - "squizlabs/php_codesniffer": "2.0.*@ALPHA" | |
33 | - }, | |
34 | - "type": "library", | |
35 | - "extra": { | |
36 | - "branch-alias": { | |
37 | - "dev-master": "1.0.x-dev" | |
38 | - } | |
39 | - }, | |
40 | - "autoload": { | |
41 | - "psr-0": { | |
42 | - "Doctrine\\Instantiator\\": "src" | |
43 | - } | |
44 | - }, | |
45 | - "notification-url": "https://packagist.org/downloads/", | |
46 | - "license": [ | |
47 | - "MIT" | |
48 | - ], | |
49 | - "authors": [ | |
50 | - { | |
51 | - "name": "Marco Pivetta", | |
52 | - "email": "ocramius@gmail.com", | |
53 | - "homepage": "http://ocramius.github.com/" | |
54 | - } | |
55 | - ], | |
56 | - "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", | |
57 | - "homepage": "https://github.com/doctrine/instantiator", | |
58 | - "keywords": [ | |
59 | - "constructor", | |
60 | - "instantiate" | |
61 | - ], | |
62 | - "time": "2014-10-13 12:58:55" | |
63 | - }, | |
64 | - { | |
65 | - "name": "mikey179/vfsStream", | |
66 | - "version": "v1.5.0", | |
67 | - "source": { | |
68 | - "type": "git", | |
69 | - "url": "https://github.com/mikey179/vfsStream.git", | |
70 | - "reference": "4dc0d2f622412f561f5b242b19b98068bbbc883a" | |
71 | - }, | |
72 | - "dist": { | |
73 | - "type": "zip", | |
74 | - "url": "https://api.github.com/repos/mikey179/vfsStream/zipball/4dc0d2f622412f561f5b242b19b98068bbbc883a", | |
75 | - "reference": "4dc0d2f622412f561f5b242b19b98068bbbc883a", | |
76 | - "shasum": "" | |
77 | - }, | |
78 | - "require": { | |
79 | - "php": ">=5.3.0" | |
80 | - }, | |
81 | - "require-dev": { | |
82 | - "phpunit/phpunit": "~4.5" | |
83 | - }, | |
84 | - "type": "library", | |
85 | - "extra": { | |
86 | - "branch-alias": { | |
87 | - "dev-master": "1.5.x-dev" | |
88 | - } | |
89 | - }, | |
90 | - "autoload": { | |
91 | - "psr-0": { | |
92 | - "org\\bovigo\\vfs\\": "src/main/php" | |
93 | - } | |
94 | - }, | |
95 | - "notification-url": "https://packagist.org/downloads/", | |
96 | - "license": [ | |
97 | - "BSD-3-Clause" | |
98 | - ], | |
99 | - "authors": [ | |
100 | - { | |
101 | - "name": "Frank Kleine", | |
102 | - "homepage": "http://frankkleine.de/", | |
103 | - "role": "Developer" | |
104 | - } | |
105 | - ], | |
106 | - "description": "Virtual file system to mock the real file system in unit tests.", | |
107 | - "homepage": "http://vfs.bovigo.org/", | |
108 | - "time": "2015-03-29 11:19:49" | |
109 | - }, | |
110 | - { | |
111 | - "name": "phpdocumentor/reflection-docblock", | |
112 | - "version": "2.0.4", | |
113 | - "source": { | |
114 | - "type": "git", | |
115 | - "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", | |
116 | - "reference": "d68dbdc53dc358a816f00b300704702b2eaff7b8" | |
117 | - }, | |
118 | - "dist": { | |
119 | - "type": "zip", | |
120 | - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/d68dbdc53dc358a816f00b300704702b2eaff7b8", | |
121 | - "reference": "d68dbdc53dc358a816f00b300704702b2eaff7b8", | |
122 | - "shasum": "" | |
123 | - }, | |
124 | - "require": { | |
125 | - "php": ">=5.3.3" | |
126 | - }, | |
127 | - "require-dev": { | |
128 | - "phpunit/phpunit": "~4.0" | |
129 | - }, | |
130 | - "suggest": { | |
131 | - "dflydev/markdown": "~1.0", | |
132 | - "erusev/parsedown": "~1.0" | |
133 | - }, | |
134 | - "type": "library", | |
135 | - "extra": { | |
136 | - "branch-alias": { | |
137 | - "dev-master": "2.0.x-dev" | |
138 | - } | |
139 | - }, | |
140 | - "autoload": { | |
141 | - "psr-0": { | |
142 | - "phpDocumentor": [ | |
143 | - "src/" | |
144 | - ] | |
145 | - } | |
146 | - }, | |
147 | - "notification-url": "https://packagist.org/downloads/", | |
148 | - "license": [ | |
149 | - "MIT" | |
150 | - ], | |
151 | - "authors": [ | |
152 | - { | |
153 | - "name": "Mike van Riel", | |
154 | - "email": "mike.vanriel@naenius.com" | |
155 | - } | |
156 | - ], | |
157 | - "time": "2015-02-03 12:10:50" | |
158 | - }, | |
159 | - { | |
160 | - "name": "phpspec/prophecy", | |
161 | - "version": "1.4.0", | |
162 | - "source": { | |
163 | - "type": "git", | |
164 | - "url": "https://github.com/phpspec/prophecy.git", | |
165 | - "reference": "8724cd239f8ef4c046f55a3b18b4d91cc7f3e4c5" | |
166 | - }, | |
167 | - "dist": { | |
168 | - "type": "zip", | |
169 | - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/8724cd239f8ef4c046f55a3b18b4d91cc7f3e4c5", | |
170 | - "reference": "8724cd239f8ef4c046f55a3b18b4d91cc7f3e4c5", | |
171 | - "shasum": "" | |
172 | - }, | |
173 | - "require": { | |
174 | - "doctrine/instantiator": "^1.0.2", | |
175 | - "phpdocumentor/reflection-docblock": "~2.0", | |
176 | - "sebastian/comparator": "~1.1" | |
177 | - }, | |
178 | - "require-dev": { | |
179 | - "phpspec/phpspec": "~2.0" | |
180 | - }, | |
181 | - "type": "library", | |
182 | - "extra": { | |
183 | - "branch-alias": { | |
184 | - "dev-master": "1.4.x-dev" | |
185 | - } | |
186 | - }, | |
187 | - "autoload": { | |
188 | - "psr-0": { | |
189 | - "Prophecy\\": "src/" | |
190 | - } | |
191 | - }, | |
192 | - "notification-url": "https://packagist.org/downloads/", | |
193 | - "license": [ | |
194 | - "MIT" | |
195 | - ], | |
196 | - "authors": [ | |
197 | - { | |
198 | - "name": "Konstantin Kudryashov", | |
199 | - "email": "ever.zet@gmail.com", | |
200 | - "homepage": "http://everzet.com" | |
201 | - }, | |
202 | - { | |
203 | - "name": "Marcello Duarte", | |
204 | - "email": "marcello.duarte@gmail.com" | |
205 | - } | |
206 | - ], | |
207 | - "description": "Highly opinionated mocking framework for PHP 5.3+", | |
208 | - "homepage": "https://github.com/phpspec/prophecy", | |
209 | - "keywords": [ | |
210 | - "Double", | |
211 | - "Dummy", | |
212 | - "fake", | |
213 | - "mock", | |
214 | - "spy", | |
215 | - "stub" | |
216 | - ], | |
217 | - "time": "2015-03-27 19:31:25" | |
218 | - }, | |
219 | - { | |
220 | - "name": "phpunit/php-code-coverage", | |
221 | - "version": "2.0.15", | |
222 | - "source": { | |
223 | - "type": "git", | |
224 | - "url": "https://github.com/sebastianbergmann/php-code-coverage.git", | |
225 | - "reference": "34cc484af1ca149188d0d9e91412191e398e0b67" | |
226 | - }, | |
227 | - "dist": { | |
228 | - "type": "zip", | |
229 | - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/34cc484af1ca149188d0d9e91412191e398e0b67", | |
230 | - "reference": "34cc484af1ca149188d0d9e91412191e398e0b67", | |
231 | - "shasum": "" | |
232 | - }, | |
233 | - "require": { | |
234 | - "php": ">=5.3.3", | |
235 | - "phpunit/php-file-iterator": "~1.3", | |
236 | - "phpunit/php-text-template": "~1.2", | |
237 | - "phpunit/php-token-stream": "~1.3", | |
238 | - "sebastian/environment": "~1.0", | |
239 | - "sebastian/version": "~1.0" | |
240 | - }, | |
241 | - "require-dev": { | |
242 | - "ext-xdebug": ">=2.1.4", | |
243 | - "phpunit/phpunit": "~4" | |
244 | - }, | |
245 | - "suggest": { | |
246 | - "ext-dom": "*", | |
247 | - "ext-xdebug": ">=2.2.1", | |
248 | - "ext-xmlwriter": "*" | |
249 | - }, | |
250 | - "type": "library", | |
251 | - "extra": { | |
252 | - "branch-alias": { | |
253 | - "dev-master": "2.0.x-dev" | |
254 | - } | |
255 | - }, | |
256 | - "autoload": { | |
257 | - "classmap": [ | |
258 | - "src/" | |
259 | - ] | |
260 | - }, | |
261 | - "notification-url": "https://packagist.org/downloads/", | |
262 | - "license": [ | |
263 | - "BSD-3-Clause" | |
264 | - ], | |
265 | - "authors": [ | |
266 | - { | |
267 | - "name": "Sebastian Bergmann", | |
268 | - "email": "sb@sebastian-bergmann.de", | |
269 | - "role": "lead" | |
270 | - } | |
271 | - ], | |
272 | - "description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.", | |
273 | - "homepage": "https://github.com/sebastianbergmann/php-code-coverage", | |
274 | - "keywords": [ | |
275 | - "coverage", | |
276 | - "testing", | |
277 | - "xunit" | |
278 | - ], | |
279 | - "time": "2015-01-24 10:06:35" | |
280 | - }, | |
281 | - { | |
282 | - "name": "phpunit/php-file-iterator", | |
283 | - "version": "1.3.4", | |
284 | - "source": { | |
285 | - "type": "git", | |
286 | - "url": "https://github.com/sebastianbergmann/php-file-iterator.git", | |
287 | - "reference": "acd690379117b042d1c8af1fafd61bde001bf6bb" | |
288 | - }, | |
289 | - "dist": { | |
290 | - "type": "zip", | |
291 | - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/acd690379117b042d1c8af1fafd61bde001bf6bb", | |
292 | - "reference": "acd690379117b042d1c8af1fafd61bde001bf6bb", | |
293 | - "shasum": "" | |
294 | - }, | |
295 | - "require": { | |
296 | - "php": ">=5.3.3" | |
297 | - }, | |
298 | - "type": "library", | |
299 | - "autoload": { | |
300 | - "classmap": [ | |
301 | - "File/" | |
302 | - ] | |
303 | - }, | |
304 | - "notification-url": "https://packagist.org/downloads/", | |
305 | - "include-path": [ | |
306 | - "" | |
307 | - ], | |
308 | - "license": [ | |
309 | - "BSD-3-Clause" | |
310 | - ], | |
311 | - "authors": [ | |
312 | - { | |
313 | - "name": "Sebastian Bergmann", | |
314 | - "email": "sb@sebastian-bergmann.de", | |
315 | - "role": "lead" | |
316 | - } | |
317 | - ], | |
318 | - "description": "FilterIterator implementation that filters files based on a list of suffixes.", | |
319 | - "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", | |
320 | - "keywords": [ | |
321 | - "filesystem", | |
322 | - "iterator" | |
323 | - ], | |
324 | - "time": "2013-10-10 15:34:57" | |
325 | - }, | |
326 | - { | |
327 | - "name": "phpunit/php-text-template", | |
328 | - "version": "1.2.0", | |
329 | - "source": { | |
330 | - "type": "git", | |
331 | - "url": "https://github.com/sebastianbergmann/php-text-template.git", | |
332 | - "reference": "206dfefc0ffe9cebf65c413e3d0e809c82fbf00a" | |
333 | - }, | |
334 | - "dist": { | |
335 | - "type": "zip", | |
336 | - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/206dfefc0ffe9cebf65c413e3d0e809c82fbf00a", | |
337 | - "reference": "206dfefc0ffe9cebf65c413e3d0e809c82fbf00a", | |
338 | - "shasum": "" | |
339 | - }, | |
340 | - "require": { | |
341 | - "php": ">=5.3.3" | |
342 | - }, | |
343 | - "type": "library", | |
344 | - "autoload": { | |
345 | - "classmap": [ | |
346 | - "Text/" | |
347 | - ] | |
348 | - }, | |
349 | - "notification-url": "https://packagist.org/downloads/", | |
350 | - "include-path": [ | |
351 | - "" | |
352 | - ], | |
353 | - "license": [ | |
354 | - "BSD-3-Clause" | |
355 | - ], | |
356 | - "authors": [ | |
357 | - { | |
358 | - "name": "Sebastian Bergmann", | |
359 | - "email": "sb@sebastian-bergmann.de", | |
360 | - "role": "lead" | |
361 | - } | |
362 | - ], | |
363 | - "description": "Simple template engine.", | |
364 | - "homepage": "https://github.com/sebastianbergmann/php-text-template/", | |
365 | - "keywords": [ | |
366 | - "template" | |
367 | - ], | |
368 | - "time": "2014-01-30 17:20:04" | |
369 | - }, | |
370 | - { | |
371 | - "name": "phpunit/php-timer", | |
372 | - "version": "1.0.5", | |
373 | - "source": { | |
374 | - "type": "git", | |
375 | - "url": "https://github.com/sebastianbergmann/php-timer.git", | |
376 | - "reference": "19689d4354b295ee3d8c54b4f42c3efb69cbc17c" | |
377 | - }, | |
378 | - "dist": { | |
379 | - "type": "zip", | |
380 | - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/19689d4354b295ee3d8c54b4f42c3efb69cbc17c", | |
381 | - "reference": "19689d4354b295ee3d8c54b4f42c3efb69cbc17c", | |
382 | - "shasum": "" | |
383 | - }, | |
384 | - "require": { | |
385 | - "php": ">=5.3.3" | |
386 | - }, | |
387 | - "type": "library", | |
388 | - "autoload": { | |
389 | - "classmap": [ | |
390 | - "PHP/" | |
391 | - ] | |
392 | - }, | |
393 | - "notification-url": "https://packagist.org/downloads/", | |
394 | - "include-path": [ | |
395 | - "" | |
396 | - ], | |
397 | - "license": [ | |
398 | - "BSD-3-Clause" | |
399 | - ], | |
400 | - "authors": [ | |
401 | - { | |
402 | - "name": "Sebastian Bergmann", | |
403 | - "email": "sb@sebastian-bergmann.de", | |
404 | - "role": "lead" | |
405 | - } | |
406 | - ], | |
407 | - "description": "Utility class for timing", | |
408 | - "homepage": "https://github.com/sebastianbergmann/php-timer/", | |
409 | - "keywords": [ | |
410 | - "timer" | |
411 | - ], | |
412 | - "time": "2013-08-02 07:42:54" | |
413 | - }, | |
414 | - { | |
415 | - "name": "phpunit/php-token-stream", | |
416 | - "version": "1.4.0", | |
417 | - "source": { | |
418 | - "type": "git", | |
419 | - "url": "https://github.com/sebastianbergmann/php-token-stream.git", | |
420 | - "reference": "db32c18eba00b121c145575fcbcd4d4d24e6db74" | |
421 | - }, | |
422 | - "dist": { | |
423 | - "type": "zip", | |
424 | - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/db32c18eba00b121c145575fcbcd4d4d24e6db74", | |
425 | - "reference": "db32c18eba00b121c145575fcbcd4d4d24e6db74", | |
426 | - "shasum": "" | |
427 | - }, | |
428 | - "require": { | |
429 | - "ext-tokenizer": "*", | |
430 | - "php": ">=5.3.3" | |
431 | - }, | |
432 | - "require-dev": { | |
433 | - "phpunit/phpunit": "~4.2" | |
434 | - }, | |
435 | - "type": "library", | |
436 | - "extra": { | |
437 | - "branch-alias": { | |
438 | - "dev-master": "1.4-dev" | |
439 | - } | |
440 | - }, | |
441 | - "autoload": { | |
442 | - "classmap": [ | |
443 | - "src/" | |
444 | - ] | |
445 | - }, | |
446 | - "notification-url": "https://packagist.org/downloads/", | |
447 | - "license": [ | |
448 | - "BSD-3-Clause" | |
449 | - ], | |
450 | - "authors": [ | |
451 | - { | |
452 | - "name": "Sebastian Bergmann", | |
453 | - "email": "sebastian@phpunit.de" | |
454 | - } | |
455 | - ], | |
456 | - "description": "Wrapper around PHP's tokenizer extension.", | |
457 | - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", | |
458 | - "keywords": [ | |
459 | - "tokenizer" | |
460 | - ], | |
461 | - "time": "2015-01-17 09:51:32" | |
462 | - }, | |
463 | - { | |
464 | - "name": "phpunit/phpunit", | |
465 | - "version": "4.5.1", | |
466 | - "source": { | |
467 | - "type": "git", | |
468 | - "url": "https://github.com/sebastianbergmann/phpunit.git", | |
469 | - "reference": "d6429b0995b24a2d9dfe5587ee3a7071c1161af4" | |
470 | - }, | |
471 | - "dist": { | |
472 | - "type": "zip", | |
473 | - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/d6429b0995b24a2d9dfe5587ee3a7071c1161af4", | |
474 | - "reference": "d6429b0995b24a2d9dfe5587ee3a7071c1161af4", | |
475 | - "shasum": "" | |
476 | - }, | |
477 | - "require": { | |
478 | - "ext-dom": "*", | |
479 | - "ext-json": "*", | |
480 | - "ext-pcre": "*", | |
481 | - "ext-reflection": "*", | |
482 | - "ext-spl": "*", | |
483 | - "php": ">=5.3.3", | |
484 | - "phpspec/prophecy": "~1.3,>=1.3.1", | |
485 | - "phpunit/php-code-coverage": "~2.0,>=2.0.11", | |
486 | - "phpunit/php-file-iterator": "~1.3.2", | |
487 | - "phpunit/php-text-template": "~1.2", | |
488 | - "phpunit/php-timer": "~1.0.2", | |
489 | - "phpunit/phpunit-mock-objects": "~2.3", | |
490 | - "sebastian/comparator": "~1.1", | |
491 | - "sebastian/diff": "~1.1", | |
492 | - "sebastian/environment": "~1.2", | |
493 | - "sebastian/exporter": "~1.2", | |
494 | - "sebastian/global-state": "~1.0", | |
495 | - "sebastian/version": "~1.0", | |
496 | - "symfony/yaml": "~2.0" | |
497 | - }, | |
498 | - "suggest": { | |
499 | - "phpunit/php-invoker": "~1.1" | |
500 | - }, | |
501 | - "bin": [ | |
502 | - "phpunit" | |
503 | - ], | |
504 | - "type": "library", | |
505 | - "extra": { | |
506 | - "branch-alias": { | |
507 | - "dev-master": "4.5.x-dev" | |
508 | - } | |
509 | - }, | |
510 | - "autoload": { | |
511 | - "classmap": [ | |
512 | - "src/" | |
513 | - ] | |
514 | - }, | |
515 | - "notification-url": "https://packagist.org/downloads/", | |
516 | - "license": [ | |
517 | - "BSD-3-Clause" | |
518 | - ], | |
519 | - "authors": [ | |
520 | - { | |
521 | - "name": "Sebastian Bergmann", | |
522 | - "email": "sebastian@phpunit.de", | |
523 | - "role": "lead" | |
524 | - } | |
525 | - ], | |
526 | - "description": "The PHP Unit Testing framework.", | |
527 | - "homepage": "https://phpunit.de/", | |
528 | - "keywords": [ | |
529 | - "phpunit", | |
530 | - "testing", | |
531 | - "xunit" | |
532 | - ], | |
533 | - "time": "2015-03-29 09:24:05" | |
534 | - }, | |
535 | - { | |
536 | - "name": "phpunit/phpunit-mock-objects", | |
537 | - "version": "2.3.0", | |
538 | - "source": { | |
539 | - "type": "git", | |
540 | - "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git", | |
541 | - "reference": "c63d2367247365f688544f0d500af90a11a44c65" | |
542 | - }, | |
543 | - "dist": { | |
544 | - "type": "zip", | |
545 | - "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/c63d2367247365f688544f0d500af90a11a44c65", | |
546 | - "reference": "c63d2367247365f688544f0d500af90a11a44c65", | |
547 | - "shasum": "" | |
548 | - }, | |
549 | - "require": { | |
550 | - "doctrine/instantiator": "~1.0,>=1.0.1", | |
551 | - "php": ">=5.3.3", | |
552 | - "phpunit/php-text-template": "~1.2" | |
553 | - }, | |
554 | - "require-dev": { | |
555 | - "phpunit/phpunit": "~4.3" | |
556 | - }, | |
557 | - "suggest": { | |
558 | - "ext-soap": "*" | |
559 | - }, | |
560 | - "type": "library", | |
561 | - "extra": { | |
562 | - "branch-alias": { | |
563 | - "dev-master": "2.3.x-dev" | |
564 | - } | |
565 | - }, | |
566 | - "autoload": { | |
567 | - "classmap": [ | |
568 | - "src/" | |
569 | - ] | |
570 | - }, | |
571 | - "notification-url": "https://packagist.org/downloads/", | |
572 | - "license": [ | |
573 | - "BSD-3-Clause" | |
574 | - ], | |
575 | - "authors": [ | |
576 | - { | |
577 | - "name": "Sebastian Bergmann", | |
578 | - "email": "sb@sebastian-bergmann.de", | |
579 | - "role": "lead" | |
580 | - } | |
581 | - ], | |
582 | - "description": "Mock Object library for PHPUnit", | |
583 | - "homepage": "https://github.com/sebastianbergmann/phpunit-mock-objects/", | |
584 | - "keywords": [ | |
585 | - "mock", | |
586 | - "xunit" | |
587 | - ], | |
588 | - "time": "2014-10-03 05:12:11" | |
589 | - }, | |
590 | - { | |
591 | - "name": "sebastian/comparator", | |
592 | - "version": "1.1.1", | |
593 | - "source": { | |
594 | - "type": "git", | |
595 | - "url": "https://github.com/sebastianbergmann/comparator.git", | |
596 | - "reference": "1dd8869519a225f7f2b9eb663e225298fade819e" | |
597 | - }, | |
598 | - "dist": { | |
599 | - "type": "zip", | |
600 | - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/1dd8869519a225f7f2b9eb663e225298fade819e", | |
601 | - "reference": "1dd8869519a225f7f2b9eb663e225298fade819e", | |
602 | - "shasum": "" | |
603 | - }, | |
604 | - "require": { | |
605 | - "php": ">=5.3.3", | |
606 | - "sebastian/diff": "~1.2", | |
607 | - "sebastian/exporter": "~1.2" | |
608 | - }, | |
609 | - "require-dev": { | |
610 | - "phpunit/phpunit": "~4.4" | |
611 | - }, | |
612 | - "type": "library", | |
613 | - "extra": { | |
614 | - "branch-alias": { | |
615 | - "dev-master": "1.1.x-dev" | |
616 | - } | |
617 | - }, | |
618 | - "autoload": { | |
619 | - "classmap": [ | |
620 | - "src/" | |
621 | - ] | |
622 | - }, | |
623 | - "notification-url": "https://packagist.org/downloads/", | |
624 | - "license": [ | |
625 | - "BSD-3-Clause" | |
626 | - ], | |
627 | - "authors": [ | |
628 | - { | |
629 | - "name": "Jeff Welch", | |
630 | - "email": "whatthejeff@gmail.com" | |
631 | - }, | |
632 | - { | |
633 | - "name": "Volker Dusch", | |
634 | - "email": "github@wallbash.com" | |
635 | - }, | |
636 | - { | |
637 | - "name": "Bernhard Schussek", | |
638 | - "email": "bschussek@2bepublished.at" | |
639 | - }, | |
640 | - { | |
641 | - "name": "Sebastian Bergmann", | |
642 | - "email": "sebastian@phpunit.de" | |
643 | - } | |
644 | - ], | |
645 | - "description": "Provides the functionality to compare PHP values for equality", | |
646 | - "homepage": "http://www.github.com/sebastianbergmann/comparator", | |
647 | - "keywords": [ | |
648 | - "comparator", | |
649 | - "compare", | |
650 | - "equality" | |
651 | - ], | |
652 | - "time": "2015-01-29 16:28:08" | |
653 | - }, | |
654 | - { | |
655 | - "name": "sebastian/diff", | |
656 | - "version": "1.2.0", | |
657 | - "source": { | |
658 | - "type": "git", | |
659 | - "url": "https://github.com/sebastianbergmann/diff.git", | |
660 | - "reference": "5843509fed39dee4b356a306401e9dd1a931fec7" | |
661 | - }, | |
662 | - "dist": { | |
663 | - "type": "zip", | |
664 | - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/5843509fed39dee4b356a306401e9dd1a931fec7", | |
665 | - "reference": "5843509fed39dee4b356a306401e9dd1a931fec7", | |
666 | - "shasum": "" | |
667 | - }, | |
668 | - "require": { | |
669 | - "php": ">=5.3.3" | |
670 | - }, | |
671 | - "require-dev": { | |
672 | - "phpunit/phpunit": "~4.2" | |
673 | - }, | |
674 | - "type": "library", | |
675 | - "extra": { | |
676 | - "branch-alias": { | |
677 | - "dev-master": "1.2-dev" | |
678 | - } | |
679 | - }, | |
680 | - "autoload": { | |
681 | - "classmap": [ | |
682 | - "src/" | |
683 | - ] | |
684 | - }, | |
685 | - "notification-url": "https://packagist.org/downloads/", | |
686 | - "license": [ | |
687 | - "BSD-3-Clause" | |
688 | - ], | |
689 | - "authors": [ | |
690 | - { | |
691 | - "name": "Kore Nordmann", | |
692 | - "email": "mail@kore-nordmann.de" | |
693 | - }, | |
694 | - { | |
695 | - "name": "Sebastian Bergmann", | |
696 | - "email": "sebastian@phpunit.de" | |
697 | - } | |
698 | - ], | |
699 | - "description": "Diff implementation", | |
700 | - "homepage": "http://www.github.com/sebastianbergmann/diff", | |
701 | - "keywords": [ | |
702 | - "diff" | |
703 | - ], | |
704 | - "time": "2014-08-15 10:29:00" | |
705 | - }, | |
706 | - { | |
707 | - "name": "sebastian/environment", | |
708 | - "version": "1.2.1", | |
709 | - "source": { | |
710 | - "type": "git", | |
711 | - "url": "https://github.com/sebastianbergmann/environment.git", | |
712 | - "reference": "6e6c71d918088c251b181ba8b3088af4ac336dd7" | |
713 | - }, | |
714 | - "dist": { | |
715 | - "type": "zip", | |
716 | - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/6e6c71d918088c251b181ba8b3088af4ac336dd7", | |
717 | - "reference": "6e6c71d918088c251b181ba8b3088af4ac336dd7", | |
718 | - "shasum": "" | |
719 | - }, | |
720 | - "require": { | |
721 | - "php": ">=5.3.3" | |
722 | - }, | |
723 | - "require-dev": { | |
724 | - "phpunit/phpunit": "~4.3" | |
725 | - }, | |
726 | - "type": "library", | |
727 | - "extra": { | |
728 | - "branch-alias": { | |
729 | - "dev-master": "1.2.x-dev" | |
730 | - } | |
731 | - }, | |
732 | - "autoload": { | |
733 | - "classmap": [ | |
734 | - "src/" | |
735 | - ] | |
736 | - }, | |
737 | - "notification-url": "https://packagist.org/downloads/", | |
738 | - "license": [ | |
739 | - "BSD-3-Clause" | |
740 | - ], | |
741 | - "authors": [ | |
742 | - { | |
743 | - "name": "Sebastian Bergmann", | |
744 | - "email": "sebastian@phpunit.de" | |
745 | - } | |
746 | - ], | |
747 | - "description": "Provides functionality to handle HHVM/PHP environments", | |
748 | - "homepage": "http://www.github.com/sebastianbergmann/environment", | |
749 | - "keywords": [ | |
750 | - "Xdebug", | |
751 | - "environment", | |
752 | - "hhvm" | |
753 | - ], | |
754 | - "time": "2014-10-25 08:00:45" | |
755 | - }, | |
756 | - { | |
757 | - "name": "sebastian/exporter", | |
758 | - "version": "1.2.0", | |
759 | - "source": { | |
760 | - "type": "git", | |
761 | - "url": "https://github.com/sebastianbergmann/exporter.git", | |
762 | - "reference": "84839970d05254c73cde183a721c7af13aede943" | |
763 | - }, | |
764 | - "dist": { | |
765 | - "type": "zip", | |
766 | - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/84839970d05254c73cde183a721c7af13aede943", | |
767 | - "reference": "84839970d05254c73cde183a721c7af13aede943", | |
768 | - "shasum": "" | |
769 | - }, | |
770 | - "require": { | |
771 | - "php": ">=5.3.3", | |
772 | - "sebastian/recursion-context": "~1.0" | |
773 | - }, | |
774 | - "require-dev": { | |
775 | - "phpunit/phpunit": "~4.4" | |
776 | - }, | |
777 | - "type": "library", | |
778 | - "extra": { | |
779 | - "branch-alias": { | |
780 | - "dev-master": "1.2.x-dev" | |
781 | - } | |
782 | - }, | |
783 | - "autoload": { | |
784 | - "classmap": [ | |
785 | - "src/" | |
786 | - ] | |
787 | - }, | |
788 | - "notification-url": "https://packagist.org/downloads/", | |
789 | - "license": [ | |
790 | - "BSD-3-Clause" | |
791 | - ], | |
792 | - "authors": [ | |
793 | - { | |
794 | - "name": "Jeff Welch", | |
795 | - "email": "whatthejeff@gmail.com" | |
796 | - }, | |
797 | - { | |
798 | - "name": "Volker Dusch", | |
799 | - "email": "github@wallbash.com" | |
800 | - }, | |
801 | - { | |
802 | - "name": "Bernhard Schussek", | |
803 | - "email": "bschussek@2bepublished.at" | |
804 | - }, | |
805 | - { | |
806 | - "name": "Sebastian Bergmann", | |
807 | - "email": "sebastian@phpunit.de" | |
808 | - }, | |
809 | - { | |
810 | - "name": "Adam Harvey", | |
811 | - "email": "aharvey@php.net" | |
812 | - } | |
813 | - ], | |
814 | - "description": "Provides the functionality to export PHP variables for visualization", | |
815 | - "homepage": "http://www.github.com/sebastianbergmann/exporter", | |
816 | - "keywords": [ | |
817 | - "export", | |
818 | - "exporter" | |
819 | - ], | |
820 | - "time": "2015-01-27 07:23:06" | |
821 | - }, | |
822 | - { | |
823 | - "name": "sebastian/global-state", | |
824 | - "version": "1.0.0", | |
825 | - "source": { | |
826 | - "type": "git", | |
827 | - "url": "https://github.com/sebastianbergmann/global-state.git", | |
828 | - "reference": "c7428acdb62ece0a45e6306f1ae85e1c05b09c01" | |
829 | - }, | |
830 | - "dist": { | |
831 | - "type": "zip", | |
832 | - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/c7428acdb62ece0a45e6306f1ae85e1c05b09c01", | |
833 | - "reference": "c7428acdb62ece0a45e6306f1ae85e1c05b09c01", | |
834 | - "shasum": "" | |
835 | - }, | |
836 | - "require": { | |
837 | - "php": ">=5.3.3" | |
838 | - }, | |
839 | - "require-dev": { | |
840 | - "phpunit/phpunit": "~4.2" | |
841 | - }, | |
842 | - "suggest": { | |
843 | - "ext-uopz": "*" | |
844 | - }, | |
845 | - "type": "library", | |
846 | - "extra": { | |
847 | - "branch-alias": { | |
848 | - "dev-master": "1.0-dev" | |
849 | - } | |
850 | - }, | |
851 | - "autoload": { | |
852 | - "classmap": [ | |
853 | - "src/" | |
854 | - ] | |
855 | - }, | |
856 | - "notification-url": "https://packagist.org/downloads/", | |
857 | - "license": [ | |
858 | - "BSD-3-Clause" | |
859 | - ], | |
860 | - "authors": [ | |
861 | - { | |
862 | - "name": "Sebastian Bergmann", | |
863 | - "email": "sebastian@phpunit.de" | |
864 | - } | |
865 | - ], | |
866 | - "description": "Snapshotting of global state", | |
867 | - "homepage": "http://www.github.com/sebastianbergmann/global-state", | |
868 | - "keywords": [ | |
869 | - "global state" | |
870 | - ], | |
871 | - "time": "2014-10-06 09:23:50" | |
872 | - }, | |
873 | - { | |
874 | - "name": "sebastian/recursion-context", | |
875 | - "version": "1.0.0", | |
876 | - "source": { | |
877 | - "type": "git", | |
878 | - "url": "https://github.com/sebastianbergmann/recursion-context.git", | |
879 | - "reference": "3989662bbb30a29d20d9faa04a846af79b276252" | |
880 | - }, | |
881 | - "dist": { | |
882 | - "type": "zip", | |
883 | - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/3989662bbb30a29d20d9faa04a846af79b276252", | |
884 | - "reference": "3989662bbb30a29d20d9faa04a846af79b276252", | |
885 | - "shasum": "" | |
886 | - }, | |
887 | - "require": { | |
888 | - "php": ">=5.3.3" | |
889 | - }, | |
890 | - "require-dev": { | |
891 | - "phpunit/phpunit": "~4.4" | |
892 | - }, | |
893 | - "type": "library", | |
894 | - "extra": { | |
895 | - "branch-alias": { | |
896 | - "dev-master": "1.0.x-dev" | |
897 | - } | |
898 | - }, | |
899 | - "autoload": { | |
900 | - "classmap": [ | |
901 | - "src/" | |
902 | - ] | |
903 | - }, | |
904 | - "notification-url": "https://packagist.org/downloads/", | |
905 | - "license": [ | |
906 | - "BSD-3-Clause" | |
907 | - ], | |
908 | - "authors": [ | |
909 | - { | |
910 | - "name": "Jeff Welch", | |
911 | - "email": "whatthejeff@gmail.com" | |
912 | - }, | |
913 | - { | |
914 | - "name": "Sebastian Bergmann", | |
915 | - "email": "sebastian@phpunit.de" | |
916 | - }, | |
917 | - { | |
918 | - "name": "Adam Harvey", | |
919 | - "email": "aharvey@php.net" | |
920 | - } | |
921 | - ], | |
922 | - "description": "Provides functionality to recursively process PHP variables", | |
923 | - "homepage": "http://www.github.com/sebastianbergmann/recursion-context", | |
924 | - "time": "2015-01-24 09:48:32" | |
925 | - }, | |
926 | - { | |
927 | - "name": "sebastian/version", | |
928 | - "version": "1.0.4", | |
929 | - "source": { | |
930 | - "type": "git", | |
931 | - "url": "https://github.com/sebastianbergmann/version.git", | |
932 | - "reference": "a77d9123f8e809db3fbdea15038c27a95da4058b" | |
933 | - }, | |
934 | - "dist": { | |
935 | - "type": "zip", | |
936 | - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/a77d9123f8e809db3fbdea15038c27a95da4058b", | |
937 | - "reference": "a77d9123f8e809db3fbdea15038c27a95da4058b", | |
938 | - "shasum": "" | |
939 | - }, | |
940 | - "type": "library", | |
941 | - "autoload": { | |
942 | - "classmap": [ | |
943 | - "src/" | |
944 | - ] | |
945 | - }, | |
946 | - "notification-url": "https://packagist.org/downloads/", | |
947 | - "license": [ | |
948 | - "BSD-3-Clause" | |
949 | - ], | |
950 | - "authors": [ | |
951 | - { | |
952 | - "name": "Sebastian Bergmann", | |
953 | - "email": "sebastian@phpunit.de", | |
954 | - "role": "lead" | |
955 | - } | |
956 | - ], | |
957 | - "description": "Library that helps with managing the version number of Git-hosted PHP projects", | |
958 | - "homepage": "https://github.com/sebastianbergmann/version", | |
959 | - "time": "2014-12-15 14:25:24" | |
960 | - }, | |
961 | - { | |
962 | - "name": "symfony/yaml", | |
963 | - "version": "v2.6.5", | |
964 | - "target-dir": "Symfony/Component/Yaml", | |
965 | - "source": { | |
966 | - "type": "git", | |
967 | - "url": "https://github.com/symfony/Yaml.git", | |
968 | - "reference": "0cd8e72071e46e15fc072270ae39ea1b66b10a9d" | |
969 | - }, | |
970 | - "dist": { | |
971 | - "type": "zip", | |
972 | - "url": "https://api.github.com/repos/symfony/Yaml/zipball/0cd8e72071e46e15fc072270ae39ea1b66b10a9d", | |
973 | - "reference": "0cd8e72071e46e15fc072270ae39ea1b66b10a9d", | |
974 | - "shasum": "" | |
975 | - }, | |
976 | - "require": { | |
977 | - "php": ">=5.3.3" | |
978 | - }, | |
979 | - "require-dev": { | |
980 | - "symfony/phpunit-bridge": "~2.7" | |
981 | - }, | |
982 | - "type": "library", | |
983 | - "extra": { | |
984 | - "branch-alias": { | |
985 | - "dev-master": "2.6-dev" | |
986 | - } | |
987 | - }, | |
988 | - "autoload": { | |
989 | - "psr-0": { | |
990 | - "Symfony\\Component\\Yaml\\": "" | |
991 | - } | |
992 | - }, | |
993 | - "notification-url": "https://packagist.org/downloads/", | |
994 | - "license": [ | |
995 | - "MIT" | |
996 | - ], | |
997 | - "authors": [ | |
998 | - { | |
999 | - "name": "Symfony Community", | |
1000 | - "homepage": "http://symfony.com/contributors" | |
1001 | - }, | |
1002 | - { | |
1003 | - "name": "Fabien Potencier", | |
1004 | - "email": "fabien@symfony.com" | |
1005 | - } | |
1006 | - ], | |
1007 | - "description": "Symfony Yaml Component", | |
1008 | - "homepage": "http://symfony.com", | |
1009 | - "time": "2015-03-12 10:28:44" | |
1010 | - } | |
1011 | - ], | |
1012 | - "aliases": [], | |
1013 | - "minimum-stability": "stable", | |
1014 | - "stability-flags": [], | |
1015 | - "prefer-stable": false, | |
1016 | - "prefer-lowest": false, | |
1017 | - "platform": { | |
1018 | - "php": ">=5.4.0" | |
1019 | - }, | |
1020 | - "platform-dev": [] | |
1021 | -} |
vendor/hranicka/csv/src/Reader.php deleted
1 | -<?php | |
2 | - | |
3 | -namespace Hranicka\Csv; | |
4 | - | |
5 | -class Reader implements \IteratorAggregate | |
6 | -{ | |
7 | - | |
8 | - /** @var string */ | |
9 | - private $filePath; | |
10 | - | |
11 | - /** @var bool */ | |
12 | - private $hasHeaderRow; | |
13 | - | |
14 | - /** @var string */ | |
15 | - private $delimiter; | |
16 | - | |
17 | - /** @var string */ | |
18 | - private $enclosure; | |
19 | - | |
20 | - /** @var string */ | |
21 | - private $escape; | |
22 | - | |
23 | - /** @var resource */ | |
24 | - private $handler; | |
25 | - | |
26 | - /** | |
27 | - * @param string $filePath CSV file path | |
28 | - * @param bool $hasHeaderRow Is the first row header? | |
29 | - */ | |
30 | - public function __construct($filePath, $hasHeaderRow = TRUE) | |
31 | - { | |
32 | - $this->filePath = $filePath; | |
33 | - $this->hasHeaderRow = $hasHeaderRow; | |
34 | - | |
35 | - $this->setup(); | |
36 | - } | |
37 | - | |
38 | - /** | |
39 | - * @param string $delimiter | |
40 | - * @param string $enclosure | |
41 | - * @param string $escape | |
42 | - * @return $this | |
43 | - */ | |
44 | - public function setup($delimiter = ';', $enclosure = '"', $escape = '\\') | |
45 | - { | |
46 | - $this->delimiter = $delimiter; | |
47 | - $this->enclosure = $enclosure; | |
48 | - $this->escape = $escape; | |
49 | - | |
50 | - return $this; | |
51 | - } | |
52 | - | |
53 | - public function getIterator() | |
54 | - { | |
55 | - return new \ArrayIterator($this->read()); | |
56 | - } | |
57 | - | |
58 | - /** | |
59 | - * @return array | |
60 | - * @throws InvalidFileException | |
61 | - * @deprecated Use ::read instead. | |
62 | - */ | |
63 | - public function parseAll() | |
64 | - { | |
65 | - return $this->read(); | |
66 | - } | |
67 | - | |
68 | - /** | |
69 | - * @return array | |
70 | - * @throws InvalidFileException | |
71 | - */ | |
72 | - public function read() | |
73 | - { | |
74 | - $return = []; | |
75 | - | |
76 | - $this->openHandler(); | |
77 | - | |
78 | - $line = 0; | |
79 | - $keys = NULL; | |
80 | - | |
81 | - while (($row = $this->readRow()) !== FALSE) { | |
82 | - $line++; | |
83 | - | |
84 | - if ($this->hasHeaderRow) { | |
85 | - if ($keys === NULL) { | |
86 | - $keys = array_values($row); | |
87 | - } else { | |
88 | - | |
89 | - if (count($keys) !== count($row)) { | |
90 | -// $rowArr = [$keys, $row]; | |
91 | -// echo "<pre>"; | |
92 | -// var_dump($rowArr); | |
93 | -// var_dump($return); | |
94 | -// echo "</pre>"; | |
95 | -// die; | |
96 | - throw new InvalidFileException("Invalid columns detected on line #$line ."); | |
97 | - // return $return; | |
98 | - } | |
99 | - | |
100 | - $return[] = array_combine($keys, $row); | |
101 | - } | |
102 | - } else { | |
103 | - $return[] = $row; | |
104 | - } | |
105 | - } | |
106 | - | |
107 | - $this->closeHandler(); | |
108 | - | |
109 | - return $return; | |
110 | - } | |
111 | - | |
112 | - private function openHandler() | |
113 | - { | |
114 | - $this->handler = fopen($this->filePath, 'r'); | |
115 | - if ($this->handler === FALSE) { | |
116 | - throw new InvalidFileException('Cannot open the file.'); | |
117 | - } | |
118 | - } | |
119 | - | |
120 | - private function closeHandler() | |
121 | - { | |
122 | - fclose($this->handler); | |
123 | - $this->handler = NULL; | |
124 | - } | |
125 | - | |
126 | - /** | |
127 | - * @return array|false | |
128 | - */ | |
129 | - private function readRow() | |
130 | - { | |
131 | - return fgetcsv($this->handler, NULL, $this->delimiter, $this->enclosure, $this->escape); | |
132 | - } | |
133 | - | |
134 | -} | |
135 | - | |
136 | -class InvalidFileException extends \Exception | |
137 | -{ | |
138 | - | |
139 | -} |
vendor/hranicka/csv/src/Writer.php deleted
1 | -<?php | |
2 | - | |
3 | -namespace Hranicka\Csv; | |
4 | - | |
5 | -class Writer | |
6 | -{ | |
7 | - | |
8 | - /** @var string */ | |
9 | - private $filePath; | |
10 | - | |
11 | - /** @var array */ | |
12 | - private $data; | |
13 | - | |
14 | - /** @var bool */ | |
15 | - private $hasHeaderRow; | |
16 | - | |
17 | - /** @var string */ | |
18 | - private $delimiter; | |
19 | - | |
20 | - /** @var string */ | |
21 | - private $enclosure; | |
22 | - | |
23 | - /** @var resource */ | |
24 | - private $handler; | |
25 | - | |
26 | - /** | |
27 | - * @param string $filePath CSV file path | |
28 | - * @param array $data | |
29 | - * @param bool $hasHeaderRow Is the first row header? | |
30 | - */ | |
31 | - public function __construct($filePath, array $data, $hasHeaderRow = TRUE) | |
32 | - { | |
33 | - $this->filePath = $filePath; | |
34 | - $this->data = $data; | |
35 | - $this->hasHeaderRow = $hasHeaderRow; | |
36 | - | |
37 | - $this->setup(); | |
38 | - } | |
39 | - | |
40 | - /** | |
41 | - * @param string $delimiter | |
42 | - * @param string $enclosure | |
43 | - * @return $this | |
44 | - */ | |
45 | - public function setup($delimiter = ',', $enclosure = '"') | |
46 | - { | |
47 | - $this->delimiter = $delimiter; | |
48 | - $this->enclosure = $enclosure; | |
49 | - | |
50 | - return $this; | |
51 | - } | |
52 | - | |
53 | - /** | |
54 | - * @return array | |
55 | - * @throws InvalidFileException | |
56 | - */ | |
57 | - public function write() | |
58 | - { | |
59 | - $this->openHandler(); | |
60 | - | |
61 | - $line = 0; | |
62 | - $keys = NULL; | |
63 | - | |
64 | - foreach ($this->data as $row) { | |
65 | - $line++; | |
66 | - | |
67 | - if ($this->hasHeaderRow) { | |
68 | - if ($keys === NULL) { | |
69 | - $keys = array_keys($row); | |
70 | - $this->writeRow($keys); | |
71 | - } | |
72 | - | |
73 | - $values = array_values($row); | |
74 | - if (count($keys) !== count($values)) { | |
75 | - throw new InvalidFileException("Invalid columns detected on line #$line."); | |
76 | - } | |
77 | - } | |
78 | - | |
79 | - $this->writeRow(array_values($row)); | |
80 | - } | |
81 | - | |
82 | - $this->closeHandler(); | |
83 | - } | |
84 | - | |
85 | - private function openHandler() | |
86 | - { | |
87 | - $this->handler = fopen($this->filePath, 'w'); | |
88 | - if ($this->handler === FALSE) { | |
89 | - throw new InvalidFileException('Cannot open the file.'); | |
90 | - } | |
91 | - } | |
92 | - | |
93 | - private function closeHandler() | |
94 | - { | |
95 | - fclose($this->handler); | |
96 | - $this->handler = NULL; | |
97 | - } | |
98 | - | |
99 | - /** | |
100 | - * @param array $data | |
101 | - * @return int | |
102 | - */ | |
103 | - private function writeRow(array $data) | |
104 | - { | |
105 | - return fputcsv($this->handler, $this->convertTypes($data), $this->delimiter, $this->enclosure); | |
106 | - } | |
107 | - | |
108 | - /** | |
109 | - * @param array $data | |
110 | - * @return array | |
111 | - */ | |
112 | - private function convertTypes(array $data) | |
113 | - { | |
114 | - foreach ($data as & $value) { | |
115 | - if (is_array($value)) { | |
116 | - $value = json_encode($value); | |
117 | - } | |
118 | - | |
119 | - $value = (string)$value; | |
120 | - } | |
121 | - | |
122 | - return $data; | |
123 | - } | |
124 | - | |
125 | -} |
vendor/hranicka/csv/tests/bootstrap.php deleted
vendor/hranicka/csv/tests/cases/ReaderTest.php deleted
1 | -<?php | |
2 | - | |
3 | -namespace Tests; | |
4 | - | |
5 | -use Hranicka\Csv\Reader; | |
6 | - | |
7 | -class ReaderTest extends \PHPUnit_Framework_TestCase | |
8 | -{ | |
9 | - | |
10 | - public function testParse1() | |
11 | - { | |
12 | - $reader = new Reader(__DIR__ . '/file1.csv'); | |
13 | - | |
14 | - $this->assertSame([ | |
15 | - [ | |
16 | - 'id' => '1', | |
17 | - 'name' => 'Homer', | |
18 | - 'gender' => 'male', | |
19 | - ], | |
20 | - [ | |
21 | - 'id' => '2', | |
22 | - 'name' => 'Bart', | |
23 | - 'gender' => 'male', | |
24 | - ], | |
25 | - [ | |
26 | - 'id' => '4', | |
27 | - 'name' => 'Lisa', | |
28 | - 'gender' => 'female', | |
29 | - ], | |
30 | - ], $reader->read()); | |
31 | - } | |
32 | - | |
33 | - public function testParse2() | |
34 | - { | |
35 | - $reader = new Reader(__DIR__ . '/file1.csv', FALSE); | |
36 | - | |
37 | - $this->assertSame([ | |
38 | - [ | |
39 | - 'id', | |
40 | - 'name', | |
41 | - 'gender', | |
42 | - ], | |
43 | - [ | |
44 | - '1', | |
45 | - 'Homer', | |
46 | - 'male', | |
47 | - ], | |
48 | - [ | |
49 | - '2', | |
50 | - 'Bart', | |
51 | - 'male', | |
52 | - ], | |
53 | - [ | |
54 | - '4', | |
55 | - 'Lisa', | |
56 | - 'female', | |
57 | - ], | |
58 | - ], $reader->read()); | |
59 | - } | |
60 | - | |
61 | - public function testParseInvalid1() | |
62 | - { | |
63 | - $reader = new Reader(__DIR__ . '/invalid1.csv'); | |
64 | - | |
65 | - $this->setExpectedExceptionRegExp('\Hranicka\Csv\InvalidFileException', '~line #2~'); | |
66 | - $reader->read(); | |
67 | - } | |
68 | - | |
69 | -} |
vendor/hranicka/csv/tests/cases/WriterTest.php deleted
1 | -<?php | |
2 | - | |
3 | -namespace Tests; | |
4 | - | |
5 | -use Hranicka\Csv\Writer; | |
6 | -use org\bovigo\vfs; | |
7 | - | |
8 | -class WriterTest extends \PHPUnit_Framework_TestCase | |
9 | -{ | |
10 | - | |
11 | - /** @var vfs\vfsStreamDirectory */ | |
12 | - private $root; | |
13 | - | |
14 | - public function setUp() | |
15 | - { | |
16 | - $this->root = vfs\vfsStream::setup(); | |
17 | - } | |
18 | - | |
19 | - public function testWrite1() | |
20 | - { | |
21 | - $data = [ | |
22 | - [ | |
23 | - 'id' => '1', | |
24 | - 'name' => 'Homer', | |
25 | - 'gender' => 'male', | |
26 | - ], | |
27 | - [ | |
28 | - 'id' => '2', | |
29 | - 'name' => 'Bart', | |
30 | - 'gender' => 'male', | |
31 | - ], | |
32 | - [ | |
33 | - 'id' => '4', | |
34 | - 'name' => 'Lisa', | |
35 | - 'gender' => 'female', | |
36 | - ], | |
37 | - ]; | |
38 | - | |
39 | - $file = vfs\vfsStream::url('root/test.csv'); | |
40 | - $writer = new Writer($file, $data); | |
41 | - $writer->write(); | |
42 | - | |
43 | - $this->assertStringEqualsFile(__DIR__ . '/file1.csv', file_get_contents($file)); | |
44 | - } | |
45 | - | |
46 | - public function testWrite2() | |
47 | - { | |
48 | - $data = [ | |
49 | - [ | |
50 | - 'id' => 1, | |
51 | - 'name' => 'Homer', | |
52 | - 'fat' => TRUE, | |
53 | - 'brain' => NULL, | |
54 | - 'data' => [1, 2, 3], | |
55 | - ], | |
56 | - ]; | |
57 | - | |
58 | - $file = vfs\vfsStream::url('root/test.csv'); | |
59 | - $writer = new Writer($file, $data); | |
60 | - $writer->write(); | |
61 | - | |
62 | - $this->assertStringEqualsFile(__DIR__ . '/file2.csv', file_get_contents($file)); | |
63 | - } | |
64 | - | |
65 | -} |
vendor/hranicka/csv/tests/cases/file1.csv deleted
vendor/hranicka/csv/tests/cases/file2.csv deleted
vendor/hranicka/csv/tests/cases/invalid1.csv deleted