Skip to content

Is there an XML mapping equivalent to @Param? #3321

Answered by harawata
phunni asked this question in Q&A
Discussion options

You must be logged in to vote

Hello @phunni ,

If you compile your project with a compiler option -parameters, you can reference the parameters by their names in the method signature.
There are some tests in this directory.


By the way, if you pass the POJO as the sole parameter of the mapper method getByName(), you can reference its properties directly in the statement (this does not require the aforementioned compiler option).

The following lines are from a test case.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by phunni
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants