title: spring replace bean name in config file with value from property file
body: <p>I have a bean config file as follows</p>
  
  <pre><code>&lt;bean id="myFactory" class="com.public.Factory"&gt;
      &lt;property name="dataSourceAdaptor" ref="${value.from.property file}Adaptor" /&gt;
  &lt;/bean&gt;
  </code></pre>
  
  <p>How do i achieve this. </p>
  
  <p>I added the following to top of the config file </p>
  
  <pre><code>&lt;util:properties id="myProperties" location="classpath:app.properties"/&gt;
  </code></pre>
  
  <p>and then tried to refer to the value using ${} but i get an error stating ${value.from.property file}Adaptor is not a valid bean</p>
  
  <p>I cannot put the whole name (xyzAdaptor) in the property file as the value in the property file is an institution and there are multiple adaptors for each institution. </p>
  
  <p>for example xzyDisplayAdaptor, xyzProductAdaptor, xyzDatasourceAdaptor</p>
  
  <p>The xyz client can change to say abc client and i want to be able to change the value in property file to abc and all the abc related beans will be injected. </p>