feat: parse content text (base case).
This commit is contained in:
@@ -1,3 +1,19 @@
|
||||
// See https://aka.ms/new-console-template for more information
|
||||
|
||||
Console.WriteLine("Hello, World!");
|
||||
using System.Text;
|
||||
using InkBlot;
|
||||
|
||||
var parser = new InkBlotParser();
|
||||
parser.Parse(new PreMadeFileReader(new Dictionary<string, string>
|
||||
{
|
||||
{ "main.ink", "Hel-\\lo!" }
|
||||
}), "main.ink");
|
||||
|
||||
|
||||
internal class PreMadeFileReader(Dictionary<string, string> filesToContents) : IFileReader
|
||||
{
|
||||
public Stream GetContents(string filename)
|
||||
{
|
||||
return new MemoryStream(Encoding.UTF8.GetBytes(filesToContents[filename]));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user