quote

martedì, febbraio 08, 2011

Spring - Referring to a String as a bean


<bean id="myString" class="java.lang.String">
<constructor-arg type="java.lang.String" value="Lucio"/>
</bean>

<bean id="myUser" class="com.benfante.User">
<property name="firstName" ref="myString"/>

</bean>

Thanks to Lucio for the example

1 commento:

Lucio Benfante ha detto...

welcome! :)