I am currently trying to write an XML file, which uses the path of "System.getProperty("user.dir")". I am using Spring 2.0 and have following code, which I want to edit so that I can somehow call the user.dir path, this example should only show what I want to do with the XML file, of course it does not work like this:
<bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="locations">
<list>
<value>file:System.getProperty("user.dir")/PATH...</value>
<value>file:System.getProperty("user.dir")/PATH...</value>
</list>
</property>
</bean>
Okay so I just found the answer by combining different approaches from other websites:
<bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="locations">
<list>
<value>file:${user.dir}/PATH...</value>
<value>file:${user.dir}/PATH...</value>
</list>
</property>