go-the-way / exl

Excel binding to struct written in Go.(Only supports Go1.18+)
Other
30 stars 9 forks source link

Don't copy files into memory if possible #8

Closed oliverkahrmann-basf closed 6 months ago

oliverkahrmann-basf commented 11 months ago

feat: Don't copy the file to memory if possible

Where possible, pass readers to the xlsx library to read file content.
Only copy the whole reader to memory if it cannot be avoided, when no file size is available.

feat: Use t.TempDir() for temporary test file

oliverkahrmann-basf commented 11 months ago

This time I made sure to test with the correct version of Go, and keep the coverage at 100% ;) Which is why I rewrote some tests for the Read*() functions to cover all edge cases.

oliverkahrmann-basf commented 8 months ago

The latest commit added now also exposes the read() function used internally, so anyone can directly read an xlsx.File if it was already parsed.