Java 在Spring中为字符串使用属性占位符
我有一个bean配置文件,必须为URL设置一个字符串属性。我想从属性文件中借用这些值Java 在Spring中为字符串使用属性占位符,java,spring,spring-el,Java,Spring,Spring El,我有一个bean配置文件,必须为URL设置一个字符串属性。我想从属性文件中借用这些值 <camel:to uri="<This is the String which i want from properties file>"/> 属性文件中存在属性1和属性2 我尝试使用SpEL,我使用的是Spring3.1,但我得到了以下错误 invalid charecter at index 0 这是我试过的EL <camel:to uri="#{example.com?
<camel:to uri="<This is the String which i want from properties file>"/>
属性文件中存在属性1和属性2
我尝试使用SpEL,我使用的是Spring3.1,但我得到了以下错误
invalid charecter at index 0
这是我试过的EL
<camel:to uri="#{example.com?from=${property1}&to=${property2}}"/>
有人能帮我吗?您在spring上下文文件中使用camel吗?
<camel:to uri="#{example.com?from=${property1}&to=${property2}}"/>