Result Data Structure: JsonQL.Compilation.ICompilationResult

Consider the following C# code snippet that loads MainExample/Example.json that depends on these JSON files (i.e., has JsonQL expressions that reference JSON objects in these files).

string[] sharedExamplesFolderPath = new string[] { "DocFiles", "MutatingJsonFiles", "Examples"};

var parametersJsonTextData = new JsonTextData("Parameters",
    LoadJsonFileHelpers.LoadJsonFile("Parameters.json", sharedExamplesFolderPath));

// countriesJsonTextData uses parametersJsonTextData for parameter parentJsonTextData
var countriesJsonTextData = new JsonTextData("Countries",
    LoadJsonFileHelpers.LoadJsonFile("Countries.json", sharedExamplesFolderPath), parametersJsonTextData);

var companiesJsonTextData = new JsonTextData("Companies",
    LoadJsonFileHelpers.LoadJsonFile("Companies.json", sharedExamplesFolderPath), countriesJsonTextData);

var filteredCompaniesJsonTextData = new JsonTextData("FilteredCompanies",
    LoadJsonFileHelpers.LoadJsonFile("FilteredCompanies.json",  sharedExamplesFolderPath), companiesJsonTextData);

// Set the value of jsonCompiler to an instance of JsonQL.Compilation.IJsonCompiler here.
// The value of JsonQL.Compilation.JsonCompiler is normally created by Dependency Injection container
// and it is normally configured as a singleton.
JsonQL.Compilation.IJsonCompiler jsonCompiler = null!;

var result = jsonCompiler.Compile(new JsonTextData("Example",
    this.LoadExampleJsonFile("Example.json"), filteredCompaniesJsonTextData));