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
Return bean proxy for model. #911
Conversation
Provides a proxy for the given part of the model whose changes are reflected back to the model Fixes #731.
Conflicts: hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModel.java
Conflicts: hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModel.java hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModelBeanUtil.java hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModelProxyHandler.java hummingbird-server/src/test/java/com/vaadin/hummingbird/template/model/TemplateModelTest.java
e1fef00
to
eb8a612
Compare
modelType.getName()), e); | ||
} catch (IllegalAccessException e) { | ||
// this should not happen | ||
throw new RuntimeException(String.format( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
e841749
to
fa06aa5
Compare
|
||
throw new UnsupportedOperationException( | ||
getUnsupportedMethodMessage(method, args)); | ||
private static boolean isAccessor(MethodDescription method) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Conflicts: hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModel.java hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModelBeanUtil.java hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModelProxyHandler.java
fa06aa5
to
4c41458
Compare
Reviewed 2 of 6 files at r2, 3 of 4 files at r4, 1 of 2 files at r5. hummingbird-server/pom.xml, line 102 [r5] (raw file):
Does byte-buddy work with OSGi? hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModel.java, line 125 [r5] (raw file):
Should you rather throw an exception if you for whatever reason reach this code? hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModelBeanUtil.java, line 141 [r5] (raw file):
FYI If you use String.split you do not have to loop an extra round and then undo the last loop using hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModelProxyHandler.java, line 130 [r5] (raw file):
Constructor defaultCtor = modelType.getConstructor() ? Comments from Reviewable |
b7b621c
to
7199a72
Compare
Review status: 5 of 7 files reviewed at latest revision, 7 unresolved discussions. hummingbird-server/pom.xml, line 102 [r5] (raw file):
|
Reviewed 1 of 1 files at r6. hummingbird-server/pom.xml, line 102 [r5] (raw file):
|
7199a72
to
e4f9fb8
Compare
Review status: 5 of 7 files reviewed at latest revision, 5 unresolved discussions. hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModelBeanUtil.java, line 141 [r5] (raw file):
|
Reviewed 1 of 2 files at r5, 1 of 1 files at r7. hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModelBeanUtil.java, line 293 [r7] (raw file):
Newline hummingbird-server/src/test/java/com/vaadin/hummingbird/template/model/TemplateModelTest.java, line 674 [r7] (raw file):
verifyBeanValue sounds like it verifies a value in a bean but in reality it sets a property in a model map and validates that the given getter returns that value? hummingbird-server/src/test/java/com/vaadin/hummingbird/template/model/TemplateModelTest.java, line 683 [r7] (raw file):
FYI Most of the three last verify* methods are about fetching the model map for a given path, which could be extracted to a helper taking a dot separated path Comments from Reviewable |
Review status: all files reviewed at latest revision, 5 unresolved discussions, some commit checks failed. hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModelBeanUtil.java, line 293 [r7] (raw file):
|
Review status: all files reviewed at latest revision, 4 unresolved discussions, some commit checks failed. hummingbird-server/src/test/java/com/vaadin/hummingbird/template/model/TemplateModelTest.java, line 674 [r7] (raw file):
|
e4f9fb8
to
b811c87
Compare
Review status: 5 of 7 files reviewed at latest revision, 4 unresolved discussions, some commit checks failed. hummingbird-server/src/test/java/com/vaadin/hummingbird/template/model/TemplateModelTest.java, line 674 [r7] (raw file):
|
Reviewed 1 of 2 files at r8, 3 of 3 files at r9. hummingbird-server/src/test/java/com/vaadin/hummingbird/template/model/TemplateModelTest.java, line 683 [r7] (raw file):
|
c69fb05
to
d71078b
Compare
Conflicts: hummingbird-server/src/main/java/com/vaadin/hummingbird/template/model/TemplateModelProxyHandler.java
Review status: 6 of 7 files reviewed at latest revision, 4 unresolved discussions. hummingbird-server/src/test/java/com/vaadin/hummingbird/template/model/TemplateModelTest.java, line 683 [r7] (raw file):
|
SonarQube analysis reported 4 issues Watch the comments in this conversation to review them. 1 extra issueNote: The following issues were found on lines that were not modified in the pull request. Because these issues can't be reported as line comments, they are summarized here:
|
Reviewed 1 of 1 files at r10. Comments from Reviewable |
Provides a proxy for the given part of the model whose changes are
reflected back to the model
Fixes #731.
This change is