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

[ModelWrapper] Copy of model with current values of properties #421

Closed
pkantner opened this issue Jul 12, 2016 · 3 comments
Closed

[ModelWrapper] Copy of model with current values of properties #421

pkantner opened this issue Jul 12, 2016 · 3 comments
Milestone

Comments

@pkantner
Copy link

As extension it would be useful, if you can get a copy of the wrapped model with the current values of each property.

Example:

public void fill(M model) {
    if (model != null) {
        fields.forEach(field -> field.commit(model));
    }
}

So you can work with a copy of the model before committing it.

@manuel-mauky
Copy link
Collaborator

Hi Philipp,
thanks for your proposal. This looks useful for some use cases.
I would name the method "copyValuesTo" instead of "fill" as it better describes what happens.

@manuel-mauky
Copy link
Collaborator

You can test the feature with version 1.6.0-SNAPSHOT.

@pkantner
Copy link
Author

Looks good 👍 Thank you

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

No branches or pull requests

2 participants