Skip to content
New issue

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

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

Already on GitHub? # to your account

Replace obsolete AssociationAttribute with new EntityAssociationAttribute on client #509

Merged

Conversation

Daniel-Svensson
Copy link
Member

@Daniel-Svensson Daniel-Svensson commented Jun 9, 2024

Replace obsolete AssociationAttribute with new EntityAssociationAttribute on client

  • The client now uses EntityAssociationAttribute internally for all logic
  • The old AssociationAttribute is still discovered and mapped to an EntityAssociationAttribute in case an old version of the code generation has been used.
  • Code generation has been updated to generate EntityAssociationAttribute instead of AssociationAttribute

PR Classification

This pull request involves an API change, specifically replacing the AssociationAttribute class with the EntityAssociationAttribute class across several files.

PR Summary

The pull request primarily focuses on the transition from AssociationAttribute to EntityAssociationAttribute in the codebase.

  • A new EntityAssociationAttribute.cs file has been added, defining the new class used to mark an Entity member as an association.
  • The AssociationAttribute class has been replaced with the EntityAssociationAttribute class in multiple files including ChangeSetBuilder.cs, Entity.cs, EntityCollection.cs, EntityRef.cs, EntitySet.cs, MetaMember.cs, and IEntityCollection.cs.
  • In MetaMember.cs, the AssociationAttribute property has been replaced with the EntityAssociationAttribute property, with added logic to handle the transition.
  • The AttributeGeneratorHelper.cs file in OpenRiaServices.Tools.TextTemplate has been updated to translate all AssociationAttribute to EntityAssociationAttribute on the client.
  • A new EntityAssociationAttributeBuilder.cs file has been added in the OpenRiaServices.Tools namespace, defining a custom attribute builder for EntityAssociationAttribute instances.

@Daniel-Svensson Daniel-Svensson changed the title Use own EntityAssociationAttribute instead of obsolete AssociationAttribute on client Replace obsolete AssociationAttribute with new EntityAssociationAttributeon client Jun 9, 2024
@Daniel-Svensson Daniel-Svensson changed the title Replace obsolete AssociationAttribute with new EntityAssociationAttributeon client Replace obsolete AssociationAttribute with new EntityAssociationAttribute on client Jun 9, 2024
Copy link

sonarqubecloud bot commented Jun 9, 2024

@Daniel-Svensson Daniel-Svensson linked an issue Jun 9, 2024 that may be closed by this pull request
@Daniel-Svensson Daniel-Svensson merged commit 6293d33 into OpenRIAServices:main Jun 9, 2024
5 checks passed
@Daniel-Svensson Daniel-Svensson deleted the associationAttribute branch June 9, 2024 21:25
@Daniel-Svensson Daniel-Svensson added this to the 5.5.0 milestone Jun 11, 2024
# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

association attribute is obsolete
1 participant