fruitl00p / php-mt940

A mt940 parser in PHP
MIT License
103 stars 60 forks source link

Can you modify your code #43

Closed stephanwoerner closed 8 years ago

stephanwoerner commented 8 years ago

I will use your programm in a symfony2 project but I have a unknown mt940 file and symfony stops every time by "trigger_error". My file starts at first line with :20: folowed by date of file formated like "ymd". Please delete line 68 in Engine.php and fill Unknown.php whit folowing code: <?php namespace Kingsquare\Parser\Banking\Mt940\Engine;

use Kingsquare\Parser\Banking\Mt940\Engine;

/**

stephanwoerner commented 8 years ago

Forget it, I have figured out that I can set my own Engine.php as parameter in function parse.

fruitl00p commented 8 years ago

You're too quick, but indeed, that would've been my answer. Instead of the trigger error, i could change that to an Exception... (namespaced et al)

Any thoughts anyone?

stephanwoerner commented 8 years ago

It's nothing to do for you but I think it can by an advantage for other programmers if you explane how to use own parser classes. Thanks.