Closed mrpdaemon closed 12 years ago
Perhaps EncFSFileInputStream should just extend java.io.InputStream and then for it to contain the FileInputStream internally. Then rather than needing to call super.XXXX it can just call innerFileInputStream.XXXX and there won't be an inheritance problem. Then if we need to change the way files are read in the future it won't change the public inheritance EncFSFileInputStream . (e.g. Perhaps in the future we want to load from urls, rather than just local files, etc.)
That sounds pretty good, I'll update the issue title :)
This refactoring is done.
Instead of extending FileInputStream, if we extend InputStream then we could implement read(byte[], int, int) without the recustion problems we've seen in Issue #3.