Commit c70e9e6
Make AbstractLocation a sealed class
Seal AbstractLocation to explicitly declare its only permitted subclasses
(Billing and Shipping). This makes the type hierarchy more explicit and
enables better pattern matching and exhaustiveness checking in Java 17+.
Note: MinFraudException was already using sealed classes.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>1 parent a0bf17c commit c70e9e6
1 file changed
Lines changed: 2 additions & 1 deletion
Lines changed: 2 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
| 11 | + | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
| |||
0 commit comments