Convert String to Code

前端 未结 18 971
轮回少年
轮回少年 2020-11-22 09:27

I want to know if there is any way to convert a String to Java compilable code.

I have a comparative expression saved in a database field. I want to re

18条回答
  •  野性不改
    2020-11-22 09:58

    StringEscapeUtils.escapeJava from Commons Lang may help if you want to generate a piece of compilable code and dump a string there.

提交回复
热议问题