IMutableElementType 接口
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
表示集合属性的元素。
public interface IMutableElementType : Microsoft.EntityFrameworkCore.Metadata.IMutableAnnotatable, Microsoft.EntityFrameworkCore.Metadata.IReadOnlyElementType
type IMutableElementType = interface
interface IReadOnlyElementType
interface IReadOnlyAnnotatable
interface IMutableAnnotatable
Public Interface IMutableElementType
Implements IMutableAnnotatable, IReadOnlyElementType
- 实现
注解
此接口在模型创建期间使用,并允许修改元数据。 生成模型后, IElementType 表示相同元数据的只读视图。
有关详细信息和示例,请参阅 为实体类型和关系建模 。
属性
ClrType |
集合中的元素类型。 (继承自 IReadOnlyElementType) |
CollectionProperty |
获取此 表示元素的集合属性。 |
IsNullable |
获取或设置一个值,该值指示集合的元素是否可以为 |
Item[String] |
获取或设置具有给定名称的批注的值。 (继承自 IMutableAnnotatable) |
方法
显式接口实现
IReadOnlyElementType.IsNullable |
获取一个值,该值指示集合的元素是否可以为 |
扩展方法
FindRelationalTypeMapping(IReadOnlyElementType) |
返回 RelationalTypeMapping 最终模型上给定元素的 。 |
GetRelationalTypeMapping(IReadOnlyElementType) |
返回 RelationalTypeMapping 最终模型上给定元素的 。 |
GetStoreType(IReadOnlyElementType) |
返回元素的数据库类型;如果找不到数据库类型, |
IsFixedLength(IReadOnlyElementType) |
返回一个标志,该标志指示元素是否能够仅存储固定长度的数据,如字符串。 |
IsFixedLength(IReadOnlyElementType, StoreObjectIdentifier) |
返回一个标志,该标志指示元素是否能够仅存储固定长度的数据,如字符串。 |
SetIsFixedLength(IMutableElementType, Nullable<Boolean>) |
设置一个标志,指示元素是否能够仅存储固定长度的数据,如字符串。 |
SetStoreType(IMutableElementType, String) |
设置元素的数据库类型。 |