beans.xml
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans
https://www.springframework.org/schema/beans/spring-beans.xsd">
<bean id="Address" class="com.geng.pojo.Address">
<property name="address" value="HanDan"/>
</bean>
<bean id="Student" class="com.geng.pojo.Student">
<!--1.普通注入-->
<property name="name" value="gengsj"/>
<!--bean注入 -->
<property name="address" ref="Address"/>
<property name="books">
<array>
<value>Beyond Feelings</value>
<value>A guide to Critical Thinking</value>
</array>
</property>
<property name="hobbies">
<list>
<value>running</value>
<value>makelove</value>
</list>
</property>
<property name="card">
<map>
<entry key="id" value="23434"/>
<entry key="bankid" value="343434343"/>
</map>
</property>
<property name="games">
<set>
<value>lol</value>
<value>hzhz</value>
</set>
</property>
<property name="wife">
<null/>
</property>
<property name="info">
<props>
<prop key="username">root</prop>
</props>
</property>
</bean>
<!-- more bean definitions go here -->
</beans>