github.com/myhau/pulumi/pkg/v3@v3.70.2-0.20221116134521-f2775972e587/codegen/testing/test/testdata/synthetic-resource-properties-pp/dotnet/synthetic-resource-properties.cs (about)

     1  using System.Collections.Generic;
     2  using Pulumi;
     3  using Synthetic = Pulumi.Synthetic.Synthetic;
     4  
     5  return await Deployment.RunAsync(() => 
     6  {
     7      var rt = new Synthetic.ResourceProperties.Root("rt");
     8  
     9      return new Dictionary<string, object?>
    10      {
    11          ["trivial"] = rt,
    12          ["simple"] = rt.Res1,
    13          ["foo"] = rt.Res1.Apply(res1 => res1.Obj1?.Res2?.Obj2),
    14          ["complex"] = rt.Res1.Apply(res1 => res1.Obj1?.Res2?.Obj2?.Answer),
    15      };
    16  });
    17