Commit ffe5feb
feat(domain): migrate Scope entity to jMolecules Entity
Changes:
- Implement jMolecules Entity<ScopeAggregate, ScopeId>
- Add getId(): ScopeId implementation
- Use _id private field with public id property (via @JvmName to avoid platform clash)
- Update factory methods to use _id parameter
- Fix ScopeAggregate.applyEvent() to use _id when creating Scope
Technical details:
- @JvmName("id") annotation prevents platform declaration clash with getId()
since ScopeId is an inline value class that mangles to the same JVM signature
- id property delegates to getId() for convenient access
- Entity type parameter references ScopeAggregate (the owning aggregate root)
Build status: ✅ SUCCESS (with expected deprecation warnings)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>1 parent ab57cc9 commit ffe5feb
File tree
2 files changed
+23
-8
lines changed- contexts/scope-management/domain/src/main/kotlin/io/github/kamiazya/scopes/scopemanagement/domain
- aggregate
- entity
2 files changed
+23
-8
lines changedLines changed: 2 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
11 | 10 | | |
12 | 11 | | |
13 | 12 | | |
| |||
28 | 27 | | |
29 | 28 | | |
30 | 29 | | |
| 30 | + | |
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| |||
145 | 145 | | |
146 | 146 | | |
147 | 147 | | |
148 | | - | |
149 | 148 | | |
150 | 149 | | |
151 | 150 | | |
| |||
194 | 193 | | |
195 | 194 | | |
196 | 195 | | |
197 | | - | |
198 | 196 | | |
199 | 197 | | |
200 | 198 | | |
| |||
352 | 350 | | |
353 | 351 | | |
354 | 352 | | |
355 | | - | |
| 353 | + | |
356 | 354 | | |
357 | 355 | | |
358 | 356 | | |
| |||
Lines changed: 21 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| 7 | + | |
7 | 8 | | |
8 | 9 | | |
9 | 10 | | |
| |||
13 | 14 | | |
14 | 15 | | |
15 | 16 | | |
| 17 | + | |
16 | 18 | | |
17 | 19 | | |
18 | 20 | | |
19 | 21 | | |
20 | 22 | | |
| 23 | + | |
21 | 24 | | |
22 | 25 | | |
23 | 26 | | |
24 | 27 | | |
25 | | - | |
| 28 | + | |
26 | 29 | | |
27 | 30 | | |
28 | 31 | | |
29 | 32 | | |
30 | 33 | | |
31 | 34 | | |
32 | 35 | | |
33 | | - | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
34 | 51 | | |
35 | 52 | | |
36 | 53 | | |
| |||
46 | 63 | | |
47 | 64 | | |
48 | 65 | | |
49 | | - | |
| 66 | + | |
50 | 67 | | |
51 | 68 | | |
52 | 69 | | |
| |||
70 | 87 | | |
71 | 88 | | |
72 | 89 | | |
73 | | - | |
| 90 | + | |
74 | 91 | | |
75 | 92 | | |
76 | 93 | | |
| |||
0 commit comments