I am writing some SpEL statements in XML, and I can't get the parser to determine when I need to escape a character.
I've attempted the following:
<... property="someProperty" value="#{ someBean.aMethodOnTheBean('st\'ring') }" />
However adding in the \' does not seem to escape that single quote and I keep receiving a parser exception.
Is there any way to escape these values?
From the documentation:
"To put a single quote itself in a string use two single quote characters."
expression = 'something = ''' + someMethod.getValue + ''''
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With