entity framework WithRequiredDependent和WithRequiredPrincipal

A->WithRequiredDependent->B

表示 A中包含B的不为null实例 ,A是主键实体  B是外键实体

A->WithRequiredPrincipal->B

表示A中包含B的不为null实例 ,A是外键实体 B是主键实体

原文地址:https://www.cnblogs.com/laogao/p/10897850.html