ChangeCaptureSource
Defined in: packages/rxdb-plugin-working-tree/src/working-tree/capture-runtime.ts:42
捕获需要的 rxdb_change 列
Remarks
刻意不收 RxDBChange 实体实例:switchBranch / mergeChanges 两个挂载点手上是还没落库的
Omit<RxDBChange, 'id'>,收实体会逼它们先造一个假 id。列集取到这里为止——多收一列,
就多一个「单元里为什么有这个字段」要回答。
Properties
entity
readonly entity: string;
Defined in: packages/rxdb-plugin-working-tree/src/working-tree/capture-runtime.ts:52
实体名
entityId
readonly entityId: string;
Defined in: packages/rxdb-plugin-working-tree/src/working-tree/capture-runtime.ts:54
实体主键
id
readonly id: number | null;
Defined in: packages/rxdb-plugin-working-tree/src/working-tree/capture-runtime.ts:44
rxdb_change.id;尚未落库的变更传 null
inversePatch
readonly inversePatch: Record<string, unknown> | null;
Defined in: packages/rxdb-plugin-working-tree/src/working-tree/capture-runtime.ts:58
逆向补丁
namespace
readonly namespace: string;
Defined in: packages/rxdb-plugin-working-tree/src/working-tree/capture-runtime.ts:50
实体命名空间
patch
readonly patch: Record<string, unknown> | null;
Defined in: packages/rxdb-plugin-working-tree/src/working-tree/capture-runtime.ts:56
正向补丁
transactionId
readonly transactionId: string | null;
Defined in: packages/rxdb-plugin-working-tree/src/working-tree/capture-runtime.ts:48
产生该变更的事务 id
type
readonly type: "INSERT" | "UPDATE" | "DELETE";
Defined in: packages/rxdb-plugin-working-tree/src/working-tree/capture-runtime.ts:46
变更种类,来自 IRxDBChange.type