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

Feat/optional static mapping #76

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

petrnymsa
Copy link

This PR adds new parameter to Mapper() annotation to optionally turn off "Static mapping".

In our project, we usually have "statci helper methods" to map the inner fields of complex objects, but such methods are only for mapping. Without this feature, for each static method a new static $_method is generated which often is not needed and moreover, sometimes it leads to compile errors.

Breaking change: NO - as this parameter is by default set to true

 - smartstruct@1.4.0
 - smartstruct_generator@1.4.0
@petrnymsa petrnymsa force-pushed the feat/optional-static branch from 03ee572 to 1d59421 Compare February 27, 2023 14:27
@petrnymsa
Copy link
Author

Hi @smotastic do you think that this feature is helpful? In our project we would like to have it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant