Co-Authored-By: Claude Sonnet 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017ic4b66uwsWr9B1ouyrzUh
11 lines
339 B
Plaintext
11 lines
339 B
Plaintext
== id-based equals/hashCode, id assigned on save ==
|
|
two unsaved entities equal? true (both ids null)
|
|
set size after adding two different unsaved entities = 1
|
|
add, then save(): set.contains(c) = false
|
|
|
|
== constant hashCode ==
|
|
add, then save(): set.contains(d) = true
|
|
|
|
== natural key, immutable ==
|
|
add, then save(): set.contains(e) = true
|