You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit e404641
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: server/java/codegen-kotlin/src/main/kotlin/com/metaobjects/generator/kotlin/KotlinExposedTableGenerator.kt
+143Lines changed: 143 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -63,6 +63,13 @@ open class KotlinExposedTableGenerator : MultiFileDirectGeneratorBase<MetaObject
63
63
// redeclare the top-level support class/extension and fail to compile.
64
64
val packagesNeedingInstantTzHelper = sortedSetOf<String>()
65
65
66
+
// Packages that emit at least one table carrying a `field.uri` or `field.inet`
67
+
// column (ADR-0036/0037 Wave 3). Each such package gets ONE shared
68
+
// `MetaInetUriColumnType.kt` support file (the custom `Column<URI>`/`Column<InetAddress>`
69
+
// column types + the `uriColumn(...)`/`inetColumn(...)` builder extensions), emitted in
70
+
// pass 3 — same multi-table-per-package sharing rationale as the instant-tz helper.
71
+
val packagesNeedingInetUriHelper = sortedSetOf<String>()
72
+
66
73
// Pass 2: emit one Table per entity using its own metadata + the
67
74
// inbound FKs accumulated in Pass 1.
68
75
// FR-024 (ADR-0028): object.projection is emitted too — a projection with
@@ -100,6 +107,12 @@ open class KotlinExposedTableGenerator : MultiFileDirectGeneratorBase<MetaObject
Copy file name to clipboardExpand all lines: server/java/codegen-kotlin/src/test/kotlin/com/metaobjects/generator/kotlin/KotlinExposedTableGeneratorTest.kt
+40Lines changed: 40 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -43,6 +43,46 @@ class KotlinExposedTableGeneratorTest {
43
43
}
44
44
}
45
45
46
+
@Test fun`field uri and field inet emit custom columns and the shared support file`() {
47
+
// ADR-0036/0037 Wave 3: a `field.uri` → `uriColumn(...)` (Column<URI> over text);
48
+
// a `field.inet` → `inetColumn(...)` (Column<InetAddress> over native inet); both
49
+
// backed by the package-shared MetaInetUriColumnType.kt support file.
0 commit comments