IMutableComplexProperty 接口
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
表示结构类型的复杂属性。
public interface IMutableComplexProperty : Microsoft.EntityFrameworkCore.Metadata.IMutablePropertyBase, Microsoft.EntityFrameworkCore.Metadata.IReadOnlyComplexProperty
type IMutableComplexProperty = interface
interface IReadOnlyComplexProperty
interface IReadOnlyPropertyBase
interface IReadOnlyAnnotatable
interface IMutablePropertyBase
interface IMutableAnnotatable
Public Interface IMutableComplexProperty
Implements IMutablePropertyBase, IReadOnlyComplexProperty
- 实现
注解
此接口在创建模型期间使用,并允许修改元数据。 生成模型后, IComplexProperty 表示相同元数据的只读视图。
有关详细信息和示例,请参阅 复杂类型 。
属性
| 名称 | 说明 |
|---|---|
| ClrType |
获取此属性类对象保存的值的类型。 (继承自 IReadOnlyPropertyBase) |
| ComplexType |
获取关联的复杂类型。 |
| DeclaringType |
获取此属性类对象所属的类型。 (继承自 IReadOnlyPropertyBase) |
| FieldInfo |
获取 FieldInfo 此属性类似对象的基础 CLR 字段。
这可能 |
| IsCollection |
获取一个值,该值指示属性是否为集合。 (继承自 IReadOnlyPropertyBase) |
| IsNullable |
获取或设置一个值,该值指示此属性是否可以包含 |
| Item[String] |
获取或设置具有给定名称的批注的值。 (继承自 IMutableAnnotatable) |
| Name |
获取类似于此属性的对象的名称。 (继承自 IReadOnlyPropertyBase) |
| PropertyInfo |
获取 PropertyInfo 此属性类似对象的基础 CLR 属性。
这可能 |
| Sentinel |
获取指示未设置此属性的 sentinel 值。 (继承自 IReadOnlyPropertyBase) |
方法
显式接口实现
| 名称 | 说明 |
|---|---|
| IReadOnlyComplexProperty.IsNullable |
获取一个值,该值指示此属性是否可以包含 |
扩展方法
| 名称 | 说明 |
|---|---|
| GetJsonPropertyName(IReadOnlyComplexProperty) |
返回属性在面向 Cosmos 时映射到的属性名称。 |
| GetJsonPropertyName(IReadOnlyComplexProperty) |
获取用于映射到 JSON 列的实体的给定复杂属性的 JSON 属性名称的值。 |
| GetMappedStoreObjects(IReadOnlyComplexProperty, StoreObjectType) |
如果映射到 JSON 列,则返回此复杂属性映射到的类似表的存储对象。 此方法通常由数据库提供程序(和其他扩展)使用。 它通常不用于应用程序代码。 |
| SetJsonPropertyName(IMutableComplexProperty, String) |
设置属性在面向 Cosmos 时映射到的属性名称。 |
| SetJsonPropertyName(IMutableComplexProperty, String) |
设置用于映射到 JSON 列的实体的给定复杂属性的 JSON 属性名称的值。 |