1 write to HostOutputs
Microsoft.CodeAnalysis (1)
SourceGeneration\RunResults.cs (1)
99this.HostOutputs = hostOutputs;
19 references to HostOutputs
Microsoft.CodeAnalysis (3)
SourceGeneration\IncrementalContexts.cs (3)
144/// via <see cref="GeneratorRunResult.HostOutputs"/> and it is up to the host to decide how to use them. 157/// via <see cref="GeneratorRunResult.HostOutputs"/> and it is up to the host to decide how to use them. 327/// here are made available via the <see cref="GeneratorRunResult.HostOutputs"/> collection, and it is up the host to
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (15)
SourceGeneration\GeneratorDriverTests.cs (15)
3249Assert.DoesNotContain(result.Results[0].HostOutputs, o => o.Key == "Host"); 3260Assert.Contains(result.Results[0].HostOutputs, o => o.Key == "Host"); 4701var (key, value) = Assert.Single(result.HostOutputs); 4721Assert.Empty(result.HostOutputs); 4737Assert.Equal(2, result.HostOutputs.Keys.Count()); 4738Assert.Contains("a", (IDictionary<string, object>)result.HostOutputs); 4739Assert.Equal("value", result.HostOutputs["a"]); 4740Assert.Contains("b", (IDictionary<string, object>)result.HostOutputs); 4741Assert.Equal("value2", result.HostOutputs["b"]); 4757Assert.Empty(result.HostOutputs); 4774(r) => { var result = Assert.Single(r.HostOutputs); Assert.Equal("gen1", result.Key); Assert.Equal("value1", result.Value); }, 4775(r) => { var result = Assert.Single(r.HostOutputs); Assert.Equal("gen2", result.Key); Assert.Equal("value2", result.Value); } 4792(r) => { var result = Assert.Single(r.HostOutputs); Assert.Equal("gen", result.Key); Assert.Equal("value1", result.Value); }, 4793(r) => { var result = Assert.Single(r.HostOutputs); Assert.Equal("gen", result.Key); Assert.Equal("value2", result.Value); } 4810Assert.Empty(result.HostOutputs);
Microsoft.CodeAnalysis.ExternalAccess.RazorCompiler (1)
GeneratorExtensions.cs (1)
35public static ImmutableArray<(string Key, string Value)> GetHostOutputs(this GeneratorRunResult runResult) => runResult.HostOutputs.ToImmutableArray().SelectAsArray(a => (a.Key, a.Value.ToString() ?? ""));