This extracts an IFilesystem and a FileFilesystem using the current implementation.
I needed to be able to listen to filesystem and web access for debugging purposes as well as to collect what AsImpL is accessing during loading. Since everything uses static calls to the .NET and Unity APIs, this is currently impossible. Extension is not possible either because the methods are private (but would be a poor choice anyway).
Functionally this is the same as it was before.
I'm not too fond of introducing static properties, but I wanted to make these changes as minimally invasive as possible. The ideal solution would be constructor injection and non-static use, but I understand that this can be problematic with MonoBehaviours in Unity, so this is the next best thing to have some extensibility, I guess.
This extracts an
IFilesystem
and aFileFilesystem
using the current implementation.I needed to be able to listen to filesystem and web access for debugging purposes as well as to collect what AsImpL is accessing during loading. Since everything uses static calls to the .NET and Unity APIs, this is currently impossible. Extension is not possible either because the methods are private (but would be a poor choice anyway).
Functionally this is the same as it was before.
I'm not too fond of introducing static properties, but I wanted to make these changes as minimally invasive as possible. The ideal solution would be constructor injection and non-static use, but I understand that this can be problematic with
MonoBehaviour
s in Unity, so this is the next best thing to have some extensibility, I guess.