@g1cloud/entity-modeler-next 5.0.10 → 5.0.11

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.
@@ -1,5 +1,39 @@
1
1
  import { Entity, LogicalModel, ModelId, SuperClassCatalog, EmbeddableCatalog } from './types';
2
2
  import { JavaTypeDef } from './javaTypes';
3
+ /**
4
+ * `AttributeConverter` FQN 기본값 — **레거시 생성기 상수 미러**(`bluework-im` `EntityJavaFile.java:77~78`
5
+ * Y/N 2종 · Money `@Convert`). 프로젝트 소유 FQN 을 emitter 상수로 두는 것은 이 파일의 확립된 관례다
6
+ * (위 `FQN` 표의 `net.g1project.*` 8개 · `PREDEF_CUSTOM_TYPE_FQN` 동형 — 카탈로그는 FQN 을 갖지 않는다).
7
+ *
8
+ * ★**여기가 단일 출처다** — 종전 Money FQN 은 `resolveJavaType` 안에 박혀 있어서, 컨버터 축이 하나 늘 때마다
9
+ * 방출 지점이 흩어질 구조였다(Y/N 축이 세 번째 자리가 될 자리). 축이 늘면 이 표에만 추가한다.
10
+ * 갈아 끼울 필요가 생기면 `ScaffoldOptions.converterCatalog` 로 축별 override 한다.
11
+ */
12
+ declare const CONVERTER_FQN: {
13
+ /** Y/N 문자 플래그 — `dataType=VARCHAR` × `PrimitiveBoolean`. */
14
+ readonly booleanYnPrimitive: "net.g1project.ecp.common.jpa.converter.PrimitiveBooleanToYNStringConverter";
15
+ /** Y/N 문자 플래그 — `dataType=VARCHAR` × `Boolean`(박싱). */
16
+ readonly booleanYnBoxed: "net.g1project.ecp.common.jpa.converter.BooleanToYNStringConverter";
17
+ /** 레거시 ③ 단일 컬럼 Money(`CustomMoneyType`). forward Money ②(2컬럼)는 `@CompositeType` 경로로 별개. */
18
+ readonly money: "net.g1project.bluecomm.money.MoneyAttributeConverter";
19
+ };
20
+ /** 컨버터 축 — `CONVERTER_FQN` 키. */
21
+ export type ConverterAxis = keyof typeof CONVERTER_FQN;
22
+ /**
23
+ * 컨버터 FQN override 카탈로그(`ScaffoldOptions.converterCatalog`). 축마다 3-상태다 —
24
+ * **미주입**=lib 내장 기본값 / **문자열**=그 FQN / **`null`**=명시 비활성(방출 생략 + `fillIn`).
25
+ *
26
+ * ★**방출 조건은 주입 대상이 아니다** — 어느 형상에 컨버터를 붙이는지는 레거시 산식으로 고정하고
27
+ * (예: Y/N 은 `VARCHAR` × boolean) **FQN 만** 프로젝트가 갈아 끼운다. 조건까지 열면 주입 규약이 곧
28
+ * 두 번째 코드젠이 된다.
29
+ *
30
+ * ★**다중값(단일 컬럼 Set) 컨버터 축은 여기 없다** — 그 컨버터는 도메인 타입별로 다르므로 프로젝트 단위
31
+ * FQN 하나로 대표할 수 없다(기본값을 두면 발명 = 「모르는 값 규약」 위반) ⇒ 현행 `fillIn` 손채움을 유지한다.
32
+ * 즉 이 표에 들어오는 것은 **종류가 정해진 축**뿐이다.
33
+ */
34
+ export type ConverterCatalog = {
35
+ readonly [K in ConverterAxis]?: string | null;
36
+ };
3
37
  export interface ScaffoldOptions {
4
38
  /**
5
39
  * **산출 불가 대상 자동 제외**(기본 `true`) — 엔티티명 미지정 / `@Id` 없는 JPA 엔티티는 파일을 만들지
@@ -16,6 +50,11 @@ export interface ScaffoldOptions {
16
50
  javaTypeCatalog?: readonly JavaTypeDef[];
17
51
  /** 임베더블 타입 해소용(EMBED_PREDEF 필드 타입·클래스명). 미주입 시 모델 type 폴백 + fillIn. */
18
52
  embeddableCatalog?: EmbeddableCatalog;
53
+ /**
54
+ * `AttributeConverter` FQN override. 미주입 시 lib 내장 `CONVERTER_FQN` 폴백(레거시 생성기 상수 미러) —
55
+ * `javaTypeCatalog` 와 같은 관용구다. 축별 3-상태·조건 비주입 근거는 {@link ConverterCatalog}.
56
+ */
57
+ converterCatalog?: ConverterCatalog;
19
58
  /**
20
59
  * `extends <superClass>` + 상속 컬럼 인덱스 해소용. 핸드오프 O3 — `SuperClassDef.packageName`이
21
60
  * "코드젠 forward 슬롯"으로 예약돼 있고 이 emitter가 그 첫 소비처다. 미주입 시 상속 컬럼/extends 미방출.
@@ -89,3 +128,4 @@ export interface ScaffoldedEntity {
89
128
  */
90
129
  export declare function isGeneratable(entity: Entity): boolean;
91
130
  export declare function scaffoldEntityJava(logical: LogicalModel, targetIds: readonly ModelId[], opts?: ScaffoldOptions): ScaffoldedEntity[];
131
+ export {};