你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

TableEntity 类

定义

表示表服务中表实体的基对象类型。

public class TableEntity : Microsoft.Azure.Cosmos.Table.ITableEntity
type TableEntity = class
    interface ITableEntity
Public Class TableEntity
Implements ITableEntity
继承
TableEntity
派生
实现

注解

TableEntity 提供 ITableEntity 接口的基实现,该接口提供 ReadEntity(IDictionary<String,EntityProperty>, OperationContext)WriteEntity(OperationContext) 方法,默认情况下,这些方法通过反射序列化和反序列化所有属性。 表实体类可以扩展此类并重写 ReadEntity(IDictionary<String,EntityProperty>, OperationContext)WriteEntity(OperationContext) 方法,以提供自定义或性能更好的序列化逻辑。

构造函数

TableEntity()

初始化 TableEntity 类的新实例。

TableEntity(String, String)

使用指定的分区键和行键初始化 TableEntity 类的新实例。

属性

DisablePropertyResolverCache

获取或设置 的属性解析程序缓存 TableEntity的状态。

ETag

获取或设置实体的 ETag。 在更新操作中,若要强制覆盖实体,请将此值设置为“*”。

PartitionKey

获取或设置实体的分区键。

RowKey

获取或设置实体的行键。

Timestamp

获取或设置实体的时间戳。

方法

ConvertBack<TResult>(IDictionary<String,EntityProperty>, EntityPropertyConverterOptions, OperationContext)

返回一个自定义实体实例,该实例使用指定的 IDictionary<TKey,TValue> 属性名称重新编译为 EntityProperty 数据类型值。

ConvertBack<TResult>(IDictionary<String,EntityProperty>, OperationContext)

返回一个自定义实体实例,该实例使用指定的 IDictionary<TKey,TValue> 属性名称重新编译为 EntityProperty 数据类型值。

Flatten(Object, EntityPropertyConverterOptions, OperationContext)

平展实体,并为指定实体对象的所有属性创建 IDictionary<TKey,TValue>EntityProperty 对象的 。

Flatten(Object, OperationContext)

平展实体,并为指定实体对象的所有属性创建 IDictionary<TKey,TValue>EntityProperty 对象的 。

ReadEntity(IDictionary<String,EntityProperty>, OperationContext)

使用将属性名称映射为类型化 IDictionary<TKey,TValue> 值的指定 EntityProperty 来反序列化实体。

ReadUserObject(Object, IDictionary<String,EntityProperty>, OperationContext)

使用 IDictionary<TKey,TValue> 数据类型化值的属性名称的指定 EntityProperty 来反序列化自定义实体实例。

WriteEntity(OperationContext)

从此 IDictionary<TKey,TValue> 实例序列化映射到 EntityProperty 数据值的属性名称的 TableEntity

WriteUserObject(Object, OperationContext)

为指定实体对象的所有属性创建 IDictionary<TKey,TValue> 对象的 EntityProperty

适用于