Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generate equals(...) and hashCode() operation also for objects with transient back references #80

Closed
jeaf-anaptecs opened this issue Mar 1, 2024 · 0 comments
Assignees
Labels
feature New feature

Comments

@jeaf-anaptecs
Copy link
Contributor

Feature Description

  • Currently equals(...) and hashCode() operation for POJOs and ServiceObjects is only generated if the class does not have any bidirectional associations
  • With a small extension to the current generator templates however it should be possible to also support equals(...) and hashCode() for classes with transaction back references (one of the ends of the associations is transient)
  • During comparision transient back references should be ignored as they are an mechanism for convinience and do not change the semantics of an object from a business perspective.
@jeaf-anaptecs jeaf-anaptecs added the feature New feature label Mar 1, 2024
@jeaf-anaptecs jeaf-anaptecs self-assigned this Mar 1, 2024
@jeaf-anaptecs jeaf-anaptecs added this to the JEAF Generator 1.17.1 milestone Mar 1, 2024
jeaf-anaptecs added a commit that referenced this issue Mar 1, 2024
jeaf-anaptecs added a commit that referenced this issue Mar 1, 2024
@jeaf-anaptecs jeaf-anaptecs changed the title Generate equals operation also for objects with transient back references Generate equals(...) and hashCode() operation also for objects with transient back references Mar 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature
Projects
None yet
Development

When branches are created from issues, their pull requests are automatically linked.

1 participant