Closed Burtsev-Alexey closed 4 years ago
are you on maven? make sure the compiler plugin setup correctly. Same if you compile with IDE (IDE must be configured with parameter names).
Yes, I'm using Maven for building. Looks like I need to add '-g:vars' compile option. It would be good to mention this in documentation, or even better do:
if(!parameter.isNamePresent()) {
throw new IllegalArgumentException("Parameter names are not present!");
}
yes, you are right. going to add it.
This code doesn't work as expected. fields always remain null.
The reason for this is demonstrated in attached image. It turned out that java doesn't preserver method arguments name, so injecting by name doesn't work.