{"repo":"sergiorodenas/stream-parser","free":true,"listed":false,"github":"https://github.com/sergiorodenas/stream-parser","clone":"git clone https://github.com/sergiorodenas/stream-parser.git","description":"⚡ PHP7 / Laravel Multi-format Streaming Parser","language":"PHP","stars":442,"topics":["laravel","streaming","parser","collections","xml","csv","json","php"],"license":"MIT","category":"api-integrations-sdks","readme_excerpt":"⚡ PHP7 / Laravel Multi-format Streaming Parser When it comes to parsing XML/CSV/JSON/... documents, there are 2 approaches to consider: DOM loading : loads all the document, making it easy to navigate and parse, and as such provides maximum flexibility for developers. Streaming : implies iterating through the document, acts like a cursor and stops at each element in its way, thus avoiding memory overkill. https://www.linkedin.com/pulse/processing-xml-documents-dom-vs-streaming-marius-ilina/ Thus, when it comes to big files, callbacks will be executed meanwhile file is downloading and will be much more efficient as far as memory is concerned. Installation Recommended usage Delegate as possible the callback execution so it doesn't blocks the document reading: (Laravel Queue based example) Practical Input/Code/Output demos XML Additionally, you could make use of to get the params of each element separated on the property. Also, could be of help to parse the very first item (usually the element that contains the elements). JSON CSV License This library is released under MIT license.","default_branch":null,"files":null,"tree":[],"storefront":"/r/sergiorodenas","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/sergiorodenas/stream-parser/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}