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

Add support for MetadataType Attribute #142

Open
wants to merge 51 commits into
base: master
Choose a base branch
from

Conversation

digitalsigi
Copy link

Adds support from MetadataType Attribute, see #40

According to https://learn.microsoft.com/en-us/dotnet/api/system.componentmodel.dataannotations.metadatatypeattribute?view=net-9.0#remarks

The MetadataType attribute can only applied to a class
The attribute cannot be inherited by derived classes.
can only applied once
Netstandard 2.0 or below is not supported
Changed code replaces the PropertyInfo from base class with PropertyInfo property of MetadataType for equal named properties.

sungam3r and others added 21 commits January 23, 2024 20:36
# Conflicts:
#	src/Destructurama.Attributed/Attributed/AttributedDestructuringPolicy.cs
Fine with me

Co-authored-by: Ivan Maximov <sungam3r@yandex.ru>
Thank you. Much better explaination! Actually this is my first contribution to such a project...

Co-authored-by: Ivan Maximov <sungam3r@yandex.ru>
…gPolicyOptions.cs


Fine with me

Co-authored-by: Ivan Maximov <sungam3r@yandex.ru>
…gPolicyOptions.cs

Co-authored-by: Ivan Maximov <sungam3r@yandex.ru>
…gPolicyOptions.cs

Co-authored-by: Ivan Maximov <sungam3r@yandex.ru>
Need additional review

Co-authored-by: Ivan Maximov <sungam3r@yandex.ru>
@github-actions github-actions bot added documentation Improvements or additions to documentation tests Pull request that adds new or changes existing tests labels Dec 22, 2024
@digitalsigi digitalsigi marked this pull request as ready for review December 22, 2024 15:55
Copy link

codecov bot commented Dec 31, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (a41383e) to head (de5be81).
Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff            @@
##            master      #142   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           11        12    +1     
  Lines          242       268   +26     
  Branches        37        41    +4     
=========================================
+ Hits           242       268   +26     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation tests Pull request that adds new or changes existing tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add support for MetadataTypeAttribute
2 participants