Пример #1
0
 private static void PopulateIndex_Rows(Microsoft.OData.Service.IUpdatable updatable, System.Collections.Generic.Dictionary<string, object> resourceLookup) {
     updatable.AddReferenceToCollection(resourceLookup["RowIndex1"], "Rows", resourceLookup["Row0"]);
     updatable.AddReferenceToCollection(resourceLookup["RowIndex3"], "Rows", resourceLookup["Row1"]);
     updatable.AddReferenceToCollection(resourceLookup["RowIndex3"], "Rows", resourceLookup["Row3"]);
     updatable.AddReferenceToCollection(resourceLookup["RowIndex4"], "Rows", resourceLookup["Row9"]);
 }
Пример #2
0
 private static void PopulatePerson_PersonMetadata(Microsoft.OData.Service.IUpdatable updatable, System.Collections.Generic.Dictionary<string, object> resourceLookup)
 {
     updatable.AddReferenceToCollection(resourceLookup["Person0"], "PersonMetadata", resourceLookup["PersonMetadata0"]);
     updatable.SetReference(resourceLookup["PersonMetadata0"], "Person", resourceLookup["Person0"]);
     updatable.AddReferenceToCollection(resourceLookup["Person0"], "PersonMetadata", resourceLookup["PersonMetadata1"]);
     updatable.SetReference(resourceLookup["PersonMetadata1"], "Person", resourceLookup["Person0"]);
     updatable.AddReferenceToCollection(resourceLookup["Person0"], "PersonMetadata", resourceLookup["PersonMetadata3"]);
     updatable.SetReference(resourceLookup["PersonMetadata3"], "Person", resourceLookup["Person0"]);
     updatable.AddReferenceToCollection(resourceLookup["Person1"], "PersonMetadata", resourceLookup["PersonMetadata4"]);
     updatable.SetReference(resourceLookup["PersonMetadata4"], "Person", resourceLookup["Person1"]);
     updatable.AddReferenceToCollection(resourceLookup["Person3"], "PersonMetadata", resourceLookup["PersonMetadata5"]);
     updatable.SetReference(resourceLookup["PersonMetadata5"], "Person", resourceLookup["Person3"]);
     updatable.AddReferenceToCollection(resourceLookup["Person3"], "PersonMetadata", resourceLookup["PersonMetadata6"]);
     updatable.SetReference(resourceLookup["PersonMetadata6"], "Person", resourceLookup["Person3"]);
     updatable.AddReferenceToCollection(resourceLookup["Person5"], "PersonMetadata", resourceLookup["PersonMetadata7"]);
     updatable.SetReference(resourceLookup["PersonMetadata7"], "Person", resourceLookup["Person5"]);
     updatable.AddReferenceToCollection(resourceLookup["Person6"], "PersonMetadata", resourceLookup["PersonMetadata8"]);
     updatable.SetReference(resourceLookup["PersonMetadata8"], "Person", resourceLookup["Person6"]);
     updatable.AddReferenceToCollection(resourceLookup["Person6"], "PersonMetadata", resourceLookup["PersonMetadata9"]);
     updatable.SetReference(resourceLookup["PersonMetadata9"], "Person", resourceLookup["Person6"]);
 }
Пример #3
0
 private static void PopulateLogin_SentMessages(Microsoft.OData.Service.IUpdatable updatable, System.Collections.Generic.Dictionary<string, object> resourceLookup)
 {
     updatable.AddReferenceToCollection(resourceLookup["Login0"], "SentMessages", resourceLookup["Message0"]);
     updatable.SetReference(resourceLookup["Message0"], "Sender", resourceLookup["Login0"]);
     updatable.AddReferenceToCollection(resourceLookup["Login1"], "SentMessages", resourceLookup["Message1"]);
     updatable.SetReference(resourceLookup["Message1"], "Sender", resourceLookup["Login1"]);
     updatable.AddReferenceToCollection(resourceLookup["Login3"], "SentMessages", resourceLookup["Message3"]);
     updatable.SetReference(resourceLookup["Message3"], "Sender", resourceLookup["Login3"]);
     updatable.AddReferenceToCollection(resourceLookup["Login3"], "SentMessages", resourceLookup["Message4"]);
     updatable.SetReference(resourceLookup["Message4"], "Sender", resourceLookup["Login3"]);
     updatable.AddReferenceToCollection(resourceLookup["Login3"], "SentMessages", resourceLookup["Message5"]);
     updatable.SetReference(resourceLookup["Message5"], "Sender", resourceLookup["Login3"]);
     updatable.AddReferenceToCollection(resourceLookup["Login5"], "SentMessages", resourceLookup["Message6"]);
     updatable.SetReference(resourceLookup["Message6"], "Sender", resourceLookup["Login5"]);
     updatable.AddReferenceToCollection(resourceLookup["Login0"], "SentMessages", resourceLookup["Message7"]);
     updatable.SetReference(resourceLookup["Message7"], "Sender", resourceLookup["Login0"]);
     updatable.AddReferenceToCollection(resourceLookup["Login5"], "SentMessages", resourceLookup["Message8"]);
     updatable.SetReference(resourceLookup["Message8"], "Sender", resourceLookup["Login5"]);
     updatable.AddReferenceToCollection(resourceLookup["Login8"], "SentMessages", resourceLookup["Message9"]);
     updatable.SetReference(resourceLookup["Message9"], "Sender", resourceLookup["Login8"]);
 }
Пример #4
0
 private static void PopulateProduct_ProductPhoto(Microsoft.OData.Service.IUpdatable updatable, System.Collections.Generic.Dictionary<string, object> resourceLookup)
 {
     updatable.AddReferenceToCollection(resourceLookup["Product0"], "Photos", resourceLookup["ProductPhoto0"]);
     updatable.AddReferenceToCollection(resourceLookup["Product0"], "Photos", resourceLookup["ProductPhoto1"]);
     updatable.AddReferenceToCollection(resourceLookup["Product0"], "Photos", resourceLookup["ProductPhoto3"]);
     updatable.AddReferenceToCollection(resourceLookup["Product0"], "Photos", resourceLookup["ProductPhoto4"]);
     updatable.AddReferenceToCollection(resourceLookup["Product0"], "Photos", resourceLookup["ProductPhoto5"]);
     updatable.AddReferenceToCollection(resourceLookup["Product1"], "Photos", resourceLookup["ProductPhoto6"]);
     updatable.AddReferenceToCollection(resourceLookup["Product3"], "Photos", resourceLookup["ProductPhoto7"]);
     updatable.AddReferenceToCollection(resourceLookup["Product3"], "Photos", resourceLookup["ProductPhoto8"]);
     updatable.AddReferenceToCollection(resourceLookup["Product6"], "Photos", resourceLookup["ProductPhoto9"]);
 }
Пример #5
0
 private static void PopulateProduct_ProductReview(Microsoft.OData.Service.IUpdatable updatable, System.Collections.Generic.Dictionary<string, object> resourceLookup)
 {
     updatable.AddReferenceToCollection(resourceLookup["Product0"], "Reviews", resourceLookup["ProductReview0"]);
     updatable.SetReference(resourceLookup["ProductReview0"], "Product", resourceLookup["Product0"]);
     updatable.AddReferenceToCollection(resourceLookup["Product0"], "Reviews", resourceLookup["ProductReview1"]);
     updatable.SetReference(resourceLookup["ProductReview1"], "Product", resourceLookup["Product0"]);
     updatable.AddReferenceToCollection(resourceLookup["Product0"], "Reviews", resourceLookup["ProductReview3"]);
     updatable.SetReference(resourceLookup["ProductReview3"], "Product", resourceLookup["Product0"]);
     updatable.AddReferenceToCollection(resourceLookup["Product0"], "Reviews", resourceLookup["ProductReview4"]);
     updatable.SetReference(resourceLookup["ProductReview4"], "Product", resourceLookup["Product0"]);
     updatable.AddReferenceToCollection(resourceLookup["Product1"], "Reviews", resourceLookup["ProductReview5"]);
     updatable.SetReference(resourceLookup["ProductReview5"], "Product", resourceLookup["Product1"]);
     updatable.AddReferenceToCollection(resourceLookup["Product0"], "Reviews", resourceLookup["ProductReview6"]);
     updatable.SetReference(resourceLookup["ProductReview6"], "Product", resourceLookup["Product0"]);
     updatable.AddReferenceToCollection(resourceLookup["Product3"], "Reviews", resourceLookup["ProductReview7"]);
     updatable.SetReference(resourceLookup["ProductReview7"], "Product", resourceLookup["Product3"]);
     updatable.AddReferenceToCollection(resourceLookup["Product3"], "Reviews", resourceLookup["ProductReview8"]);
     updatable.SetReference(resourceLookup["ProductReview8"], "Product", resourceLookup["Product3"]);
     updatable.AddReferenceToCollection(resourceLookup["Product9"], "Reviews", resourceLookup["ProductReview9"]);
     updatable.SetReference(resourceLookup["ProductReview9"], "Product", resourceLookup["Product9"]);
 }
Пример #6
0
 private static void PopulateProducts_RelatedProducts(Microsoft.OData.Service.IUpdatable updatable, System.Collections.Generic.Dictionary<string, object> resourceLookup)
 {
     updatable.AddReferenceToCollection(resourceLookup["Product0"], "RelatedProducts", resourceLookup["Product0"]);
     updatable.AddReferenceToCollection(resourceLookup["Product1"], "RelatedProducts", resourceLookup["Product1"]);
     updatable.AddReferenceToCollection(resourceLookup["Product3"], "RelatedProducts", resourceLookup["Product3"]);
     updatable.AddReferenceToCollection(resourceLookup["Product3"], "RelatedProducts", resourceLookup["Product4"]);
     updatable.AddReferenceToCollection(resourceLookup["Product5"], "RelatedProducts", resourceLookup["Product5"]);
     updatable.AddReferenceToCollection(resourceLookup["Product6"], "RelatedProducts", resourceLookup["Product6"]);
     updatable.AddReferenceToCollection(resourceLookup["Product3"], "RelatedProducts", resourceLookup["Product7"]);
     updatable.AddReferenceToCollection(resourceLookup["Product5"], "RelatedProducts", resourceLookup["Product8"]);
     updatable.AddReferenceToCollection(resourceLookup["Product8"], "RelatedProducts", resourceLookup["Product9"]);
 }
Пример #7
0
 private static void PopulateCustomer_Logins(Microsoft.OData.Service.IUpdatable updatable, System.Collections.Generic.Dictionary<string, object> resourceLookup)
 {
     updatable.AddReferenceToCollection(resourceLookup["Customer0"], "Logins", resourceLookup["Login0"]);
     updatable.SetReference(resourceLookup["Login0"], "Customer", resourceLookup["Customer0"]);
     updatable.AddReferenceToCollection(resourceLookup["Customer1"], "Logins", resourceLookup["Login1"]);
     updatable.SetReference(resourceLookup["Login1"], "Customer", resourceLookup["Customer1"]);
     updatable.AddReferenceToCollection(resourceLookup["Customer0"], "Logins", resourceLookup["Login3"]);
     updatable.SetReference(resourceLookup["Login3"], "Customer", resourceLookup["Customer0"]);
     updatable.AddReferenceToCollection(resourceLookup["Customer3"], "Logins", resourceLookup["Login4"]);
     updatable.SetReference(resourceLookup["Login4"], "Customer", resourceLookup["Customer3"]);
     updatable.AddReferenceToCollection(resourceLookup["Customer3"], "Logins", resourceLookup["Login5"]);
     updatable.SetReference(resourceLookup["Login5"], "Customer", resourceLookup["Customer3"]);
     updatable.AddReferenceToCollection(resourceLookup["Customer3"], "Logins", resourceLookup["Login6"]);
     updatable.SetReference(resourceLookup["Login6"], "Customer", resourceLookup["Customer3"]);
     updatable.AddReferenceToCollection(resourceLookup["Customer5"], "Logins", resourceLookup["Login7"]);
     updatable.SetReference(resourceLookup["Login7"], "Customer", resourceLookup["Customer5"]);
     updatable.AddReferenceToCollection(resourceLookup["Customer4"], "Logins", resourceLookup["Login8"]);
     updatable.SetReference(resourceLookup["Login8"], "Customer", resourceLookup["Customer4"]);
     updatable.AddReferenceToCollection(resourceLookup["Customer7"], "Logins", resourceLookup["Login9"]);
     updatable.SetReference(resourceLookup["Login9"], "Customer", resourceLookup["Customer7"]);
 }
Пример #8
0
 private static void PopulateMessage_Attachments(Microsoft.OData.Service.IUpdatable updatable, System.Collections.Generic.Dictionary<string, object> resourceLookup)
 {
     updatable.AddReferenceToCollection(resourceLookup["Message0"], "Attachments", resourceLookup["MessageAttachment0"]);
     updatable.AddReferenceToCollection(resourceLookup["Message1"], "Attachments", resourceLookup["MessageAttachment1"]);
     updatable.AddReferenceToCollection(resourceLookup["Message3"], "Attachments", resourceLookup["MessageAttachment3"]);
     updatable.AddReferenceToCollection(resourceLookup["Message3"], "Attachments", resourceLookup["MessageAttachment4"]);
     updatable.AddReferenceToCollection(resourceLookup["Message0"], "Attachments", resourceLookup["MessageAttachment5"]);
     updatable.AddReferenceToCollection(resourceLookup["Message6"], "Attachments", resourceLookup["MessageAttachment6"]);
     updatable.AddReferenceToCollection(resourceLookup["Message0"], "Attachments", resourceLookup["MessageAttachment7"]);
     updatable.AddReferenceToCollection(resourceLookup["Message8"], "Attachments", resourceLookup["MessageAttachment8"]);
     updatable.AddReferenceToCollection(resourceLookup["Message4"], "Attachments", resourceLookup["MessageAttachment9"]);
 }