Memory consideration
nicolas-f opened this issue · 4 comments
Hi,
Does this library load the entire read binary file into memory ?
Thanks
Hi
it depends on structure of data, the library reads streamed data and keep in memory the result of operation to return it as result, whole stream will be read in memory if you have non-sized array in your pattern
for instance
"byte [_] data;"
it will read entire (!) source stream and its result will be in memory
"byte [1024] data;"
it will read only the first kylobyte from the source stream and only the 1024 bytes will be read in memory (and placed into inside container)
Ok, thank you for your answer. Your library is very welcome as it is a nightmare in Java to parse structured binary. I'm a Python fan too ;)
I currently use your library in a driver library for a game's world map.
https://github.com/nicolas-f/7dtd_world_reader
cool!
I hope the library will be good for your purposes, contact me if you meet problems. I have written a lot of tests but may be there are missed cases