@g1cloud/entity-modeler-next 5.0.0-beta.50 → 5.0.0-beta.52

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -40,6 +40,20 @@ export declare function computeForeignAttributes(logical: LogicalModel, associat
40
40
  * 멱등(INV-5): 이미 맞춰진 상태에서 다시 호출하면 빈 계획을 돌려준다.
41
41
  */
42
42
  export declare function reconcileForeignAttributes(logical: LogicalModel, childEntityId: ModelId, idFactory?: IdFactory): ReconcilePlan;
43
+ /**
44
+ * 같은 자식에 두 번째 계획이 도착했을 때(비등깊이 다중 경로 — A→D 직행 + A→B→D 경유) 병합한다.
45
+ * next는 "원본 + base 적용" 상태 기준의 diff이므로, base의 add를 겨냥한 후속 update/remove를
46
+ * add 쪽으로 fold하면 병합 결과는 다시 *원본* 기준 diff가 된다(반환 계약 보존).
47
+ * add의 modelId는 work에 이미 적용된 것을 그대로 유지해야 한다 — 후손 계획의
48
+ * sourceAttributeRef가 이 id를 참조하므로 재계산(새 id 발급)은 정합을 깨뜨린다.
49
+ */
50
+ /**
51
+ * 두 reconcile 계획을 하나로 접는다 — 늦게 온 patch 가 이긴다(같은 속성이면 필드 단위 덮어쓰기).
52
+ * ★다중 경로 전파(CC-2)뿐 아니라 **여러 루트의 cascade 가 같은 후손에 겹칠 때**도 쓴다
53
+ * (`childReconcileWithCascade` — 다이아몬드에서 같은 자식이 두 번 계획되면 op 배치에 같은 경로의
54
+ * `$set` 이 두 번 실려 호스트가 배치를 거부한다).
55
+ */
56
+ export declare function mergePlans(base: ReconcilePlan, next: ReconcilePlan): ReconcilePlan;
43
57
  /**
44
58
  * changedEntityId의 식별자 변경이 영향을 주는 모든 후손 자식의 reconcile 계획.
45
59
  * 클론에 단계별로 적용하며 다음 단계 입력을 갱신하므로, 반환 계획은 *원본* logical 기준이다.
@@ -75,7 +75,7 @@ export declare function cascadeCommands(futureLogical: LogicalModel, parentId: M
75
75
  * (부모 식별자 자체가 바뀌는 트리거는 부모 자신 reconcile이 불필요해 cascadeCommands를 직접 쓴다.)
76
76
  * futureLogical은 트리거 변경이 이미 반영된 상태여야 한다(construction 시점 계획 고정).
77
77
  */
78
- export declare function childReconcileWithCascade(futureLogical: LogicalModel, childId: ModelId, removed: RemovedAttributes): Command[];
78
+ export declare function childReconcileWithCascade(futureLogical: LogicalModel, childIds: readonly ModelId[], removed: RemovedAttributes): Command[];
79
79
  export declare function flattenEmbeddableColumns(embeddable: Entity): DbColumn[];
80
80
  /**
81
81
  * 임베더블 → 일반 엔터티 역전환의 부수 명령(stereotype update 명령에 합성).