コード例 #1
0
        public void Generate()
        {
            var customer = new EFSelectCustomer
            {
                Id           = 1,
                SelectOrders = new List <EFSelectOrder>
                {
                    new EFSelectOrder
                    {
                        Id = 3,
                    },
                    new EFSelectOrder
                    {
                        Id = 1,
                    },
                    new EFSelectOrder
                    {
                        Id = 2,
                    }
                }
            };

            _db.Customers.Add(customer);
            _db.SaveChanges();
        }
コード例 #2
0
        public void Generate()
        {
            var customer = new EFSelectCustomer
            {
                Id           = 1,
                SelectOrders = new List <EFSelectOrder>
                {
                    new EFSelectOrder
                    {
                        Id = 3,
                    },
                    new EFSelectOrder
                    {
                        Id = 1,
                    },
                    new EFSelectOrder
                    {
                        Id = 2,
                    }
                }
            };

            _db.Customers.Add(customer);

            var wideCustomer = new EFWideCustomer
            {
                Id          = 1,
                PartitionId = 1,
                SkipToken   = 1,
                Custom1     = new CustomProperties1
                {
                    Prop0001 = "Prop0001",
                    Prop0099 = "Prop0099",
                    Prop0199 = "Prop0199",
                    Prop0298 = "Prop0298",
                    Prop0299 = "Prop0299",
                },
                Custom2 = new CustomProperties2
                {
                    Prop0798 = "Prop0798",
                },
                Custom3 = new CustomProperties3
                {
                    Prop1198 = "Prop1198",
                },
                Custom4 = new CustomProperties4
                {
                    Prop1598 = "Prop1598",
                    Prop1600 = "Prop1600",
                },
                Custom5 = new CustomProperties5
                {
                    Prop1998 = "Prop1998",
                    Prop2000 = "Prop2000",
                },
            };

            _db.WideCustomers.Add(wideCustomer);
            _db.SaveChanges();
        }
コード例 #3
0
 public void Generate()
 {
     var customer = new EFSelectCustomer
     {
         Id = 1,
         SelectOrders = new List<EFSelectOrder>
         {
             new EFSelectOrder
             {
                 Id = 3,
             },
             new EFSelectOrder
             {
                 Id = 1,
             },
             new EFSelectOrder
             {
                 Id = 2,
             }
         }
     };
     _db.Customers.Add(customer);
     _db.SaveChanges();
 }