namespace Engine.Resource;

public class MemoryResourceStreamProvider : IResourceStreamProvider
{
  private readonly Dictionary<string, byte[]> _resources = new();

  public Stream GetStream(string parPath)
  {
    return new MemoryStream(_resources[parPath]);
  }

  internal void AddResource(string parPath, byte[] parData)
  {
    _resources.Add(parPath, parData);
  }
}