val myGZIP = scala.io.Source.fromURL(...)
scala.io.BufferedSource referring to a
gzip file. I would like to use it subsequently in
val gz = new GZIPInputStream(fis)
to be able to process the file
scala.io.BufferedSource. Is there any way to convert and chain reading from URL and decoding
Well, you don’t need
Source.fromURL at all.
Just check at its implementation, all you need is:
Great, everything works perfectly! Thanks a lot for a prompt response.
fromFoo API in
Source is very confusing to me (and I’m not a user). I suspect it could be simplified. In particular, I think you are not wrong in wanting your use case without dipping back into the Java API.
I don’t know what the “correct” or “best” API would be.
I’m glad there is a workaround.