INNER CODE UNIT · C#
ShippingInfo
mongodb/mongo-efcore-provider · benchmarks/MongoDB.EntityFrameworkCore.Benchmarks/Model.Extended.cs:22
public class ShippingInfo // owned
{
public string Carrier { get; set; } = "";
public OrderAddress Address { get; set; } = new(); // nested owned
}
public class OrderAddress // owned (nested under ShippingInfo)
{
public string Street { get; set; } = "";
public string City { get; set; } = "";
public int Zip { get; set; }
}
public class LineItem // owned-collection element
{
public string Sku { get; set; } = "";
public int Qty { get; set; }
public ItemMeta Meta { get; set; } = new(); // nested owned (inside collection element)